Question: printf and print output on the same line

March 20 2014 Amber 10
0

Hi, i'm wondering if theres anything i can do printf and print and have the outputs on the same line. I want the string wihtout any quotations so i think i can only do printf to get this, but then i'm putting an entry out of an array after this. This is a small example out of my code, i would like the output to be all on one line:

The synchronising vector is (S[j-1]) The synchronising word is (X[j-1]) The length of the synchronising word is ...

 

if (sync=true) then 
printf("The Synchronising vector is"); print(S[j-1]);
printf("The sychronising word is");
print(X[j-1]);
printf("The length of the synchronising word is");
print(length(X[j-1]));
else printf("There is no synchronising word"); 
end if;

 At the moment its outputing each print on a new line.

Any help would be much appreciated, thanks.

 

Please Wait...