need for an extra variable.
- From: "chandanlinster" <chandanlinster@xxxxxxxxx>
- Date: 31 Oct 2006 01:47:12 -0800
hello everybody,
consider the following code snippet (from K & R, pg78)
while ((s[0] = c = getch()) == ' ' || c == '\t')
;
my question is, why would we need the variable 'c'.
We could easily write it as,
while ((s[0] = getch()) == ' ' || s[0] == '\t')
;
.
- Follow-Ups:
- Re: need for an extra variable.
- From: Richard Tobin
- Re: need for an extra variable.
- From: Richard Heathfield
- Re: need for an extra variable.
- From: Zero
- Re: need for an extra variable.
- Prev by Date: Re: if clause
- Next by Date: Re: finding how much the file system is full, from a C program?
- Previous by thread: realloc(): invalid next size
- Next by thread: Re: need for an extra variable.
- Index(es):