sscanf problem
#4

Hmm, I think that I don't need optional D. The point is, that if the readed line from file doesn't include 4 integers, it must check if the readed line includes 2 integers, but somehow the script think that '26|33' are four integers. Sorry my awful english but I'm trying at my best.

Little pseudo code of what I mean:

Код:
if(!sscanf(Data,"p<|>dddd",num1,num2,num3,num4))
{
//this will execute if the Data includes 4 integers
}
else
{
//this will execute if the Data does NOT include 4 integers
if(!sscanf(Data,"p<|>dd",num5,num6))
{
//this will execute if the Data includes 2 integers
}
else
{
//this will execure if the Data does NOT include 4 OR 2 integers
}
}
Somehow my code is not working . Help, please?
Reply


Messages In This Thread
sscanf problem - by Killer#Mummy - 27.07.2012, 08:54
Re: sscanf problem - by Killer#Mummy - 28.07.2012, 12:11
Re: sscanf problem - by ReneG - 28.07.2012, 13:13
Re: sscanf problem - by Killer#Mummy - 28.07.2012, 13:39

Forum Jump:


Users browsing this thread: 4 Guest(s)