Forums
New posts
Search forums
Members
Current visitors
Log in
Register
What's new
Search
Search
Search titles only
By:
New posts
Search forums
Menu
Log in
Register
Install the app
Install
Forums
Archive
Archive
C Programming
Meaning for *p = +*q++
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Reply to thread
Message
[QUOTE="Juergen Heinzl, post: 1707577"] [-] Useless unary "+" operator -> +*q++ <- here. [-] main() isn't void. [-] Useless cast and calloc (sizeof (pointer to char), sizeof (pointer to char) * sizeof (pointer to char)) probably isn't what you want, either. [-] It's a, as far as the copying is concerned, shorter form of ... while (*p = *q) { p++; q++; } .... which is a shorter form of ... *p = *q; while (*p != '\0') { p++; q++; *p = *q; } .... [-] (*q)++ means "increment the value at q". [-] Sure, as syntactically what you wrote is fine. Cheers, Juergen [/QUOTE]
Verification
Post reply
Forums
Archive
Archive
C Programming
Meaning for *p = +*q++
Top