int broj;
if (isalpha(broj)){
cout<<"in alpha!";
}
daje SIGSEGV gresku ?
I don't want to be a human. I want to see gamma rays, I want to hear x-rays and I want to smell dark matter. I want to reach out with something other than this prehensile paws and feel the solar wind of a super nova flowing over me.
Slamd64 je napisao/la:zato sto nisi nista unio. ko zna sta ti je broj. probaj cin>>broj;
eh da, jesam, samo sam tu zaboravio dodati "cin", u programu sam isto prvi puta zaboravio pa sam isto mislio da je to, ali nije.
I don't want to be a human. I want to see gamma rays, I want to hear x-rays and I want to smell dark matter. I want to reach out with something other than this prehensile paws and feel the solar wind of a super nova flowing over me.
drone je napisao/la:Je li to iz cctype headera?
Napiši cijeli kod povezan s pitanjem. Ono što si napisao ne valja jer varijabla "broj" mora imati vrijednost.
btw, to je samo testni programcic jer mi to nije radilo u programu koji pisem zapravo.
I don't want to be a human. I want to see gamma rays, I want to hear x-rays and I want to smell dark matter. I want to reach out with something other than this prehensile paws and feel the solar wind of a super nova flowing over me.
Slamd64 je napisao/la:da bi ti vratio da je slovo moras staviti tip podatka char ili promijeniti uslov u isdigit. nesto od to dvoje.
nope, "isalpha()" testira dali je dana vrijednost slovo.
I don't want to be a human. I want to see gamma rays, I want to hear x-rays and I want to smell dark matter. I want to reach out with something other than this prehensile paws and feel the solar wind of a super nova flowing over me.
blacx je napisao/la:Kompajlirao sam taj komad koda gore i radi. U čemu je točno problem? Kako kompajliraš?
koristim monodevelop v3.0.3.2, u kojemu nema direktno kompajliranje nego samo ono sa ctrl+F5
I don't want to be a human. I want to see gamma rays, I want to hear x-rays and I want to smell dark matter. I want to reach out with something other than this prehensile paws and feel the solar wind of a super nova flowing over me.