Lemmy
  • Communities
  • Create Post
  • Create Community
  • heart
    Support Lemmy
  • search
    Search
  • Login
  • Sign Up
PandaDEV@lemmy.ml to Programmer Humor@lemmy.ml · 3 个月前

unsafeCode

lemmy.ml

external-link
message-square
18
fedilink
373
external-link

unsafeCode

lemmy.ml

PandaDEV@lemmy.ml to Programmer Humor@lemmy.ml · 3 个月前
message-square
18
fedilink
  • Oriel Jutty :hhHHHAAAH:@infosec.exchange
    link
    fedilink
    arrow-up
    9
    ·
    3 个月前

    @stebo02 @Bogus5553 Neither of them require a return value, but void main isn’t legal C++.

    • stebo02@lemmy.dbzer0.com
      link
      fedilink
      arrow-up
      2
      ·
      edit-2
      16 天前

      deleted by creator

      • Bogus5553@lemm.ee
        link
        fedilink
        arrow-up
        4
        ·
        edit-2
        3 个月前

        void main(){...} is not in the standard, but works on both MSVC and GCC (with warnings). I think it works on both C/C++, but you really shouldn’t use it in production. Just use int main(void){...} , without any return value, which is permitted in the standard, and will return success iirc.

Programmer Humor@lemmy.ml

programmerhumor@lemmy.ml

Subscribe from Remote Instance

Create a post
You are not logged in. However you can subscribe from another Fediverse account, for example Lemmy or Mastodon. To do this, paste the following into the search field of your instance: !programmerhumor@lemmy.ml

Post funny things about programming here! (Or just rant about your favourite programming language.)

Rules:

  • Posts must be relevant to programming, programmers, or computer science.
  • No NSFW content.
  • Jokes must be in good taste. No hate speech, bigotry, etc.
Visibility: Public
globe

This community can be federated to other instances and be posted/commented in by their users.

  • 119 users / day
  • 1.16K users / week
  • 2.56K users / month
  • 10.4K users / 6 months
  • 1 local subscriber
  • 35.7K subscribers
  • 1.73K Posts
  • 37.5K Comments
  • Modlog
  • mods:
  • AgreeableLandscape@lemmy.ml
  • cat_programmer@lemmy.ml
  • BE: 0.19.10
  • Modlog
  • Instances
  • Docs
  • Code
  • join-lemmy.org