while(a->next)
Would this loop break when a->next is null?
Sorry i've only really done java before, not really sure how while loops work in C.
Blogs > Steelflight-Rx |
Steelflight-Rx
United States1389 Posts
while(a->next) Would this loop break when a->next is null? Sorry i've only really done java before, not really sure how while loops work in C. | ||
R1CH
Netherlands10340 Posts
| ||
IzzyCraft
United States4487 Posts
Or a is a int/double/long double and you input a character, but you can prevent that from breaking by use a ignore command err umm. cin >> a; if( !cin) { cin.clear(); //cin.ignore(); cin.ignore(100, '\n'); } But if your just incrementing a or something i doubt it would break normally =p ionno im very limited c knowlege T_T | ||
R1CH
Netherlands10340 Posts
| ||
Steelflight-Rx
United States1389 Posts
thanks for the help | ||
R1CH
Netherlands10340 Posts
| ||
| ||
Next event in 11h 5m
[ Submit Event ] |
StarCraft 2 StarCraft: Brood War Dota 2 Counter-Strike Super Smash Bros Heroes of the Storm Other Games tarik_tv19460 Grubby2808 FrodaN1320 shahzam893 Hui .207 NuckleDu105 Mew2King76 Maynarde68 -ZergGirl67 ViBE8 Organizations StarCraft 2 StarCraft: Brood War StarCraft 2 StarCraft: Brood War
StarCraft 2 • MEDOEDLive 126 StarCraft: Brood War• RyuSc2 39 • musti20045 38 • Hupsaiya 30 • davetesta1 • Poblha • aXEnki • intothetv • Gussbus • Kozan • Migwel • IndyKCrew • LaughNgamez Trovo • Laughngamez YouTube Dota 2 League of Legends Other Games |
ESL Pro Tour
World Team League
ESL Pro Tour
Reynor vs MaNa
GunGFuBanDa vs Spirit
Elazer vs Krystianer
SKillous vs MaxPax
Big Brain Bouts
Korean StarCraft League
Afreeca Starleague
hero vs Soulkey
AfreecaTV Pro Series
Reynor vs Cure
ESL Pro Tour
World Team League
ESL Pro Tour
[ Show More ] BSL
Zhanhun vs DragOn
Dewalt vs Sziky
CSO Cup
Replay Cast
Sparkling Tuna Cup
ESL Pro Tour
World Team League
ESL Pro Tour
BSL
Gypsy vs Bonyth
Mihu vs XiaoShuai
ESL Open Cup
ESL Open Cup
ESL Open Cup
ESL Pro Tour
ESL Pro Tour
|
|