[Scilab-users] mprintf("%c") actual action, and vs mprintf("%s") ?
Samuel Gougeon
sgougeon at free.fr
Wed Oct 21 20:12:12 CEST 2020
Hello,
The printf_conversion page
<https://help.scilab.org/docs/6.1.0/en_US/printf_conversion.html> tells
that the "/"%c" directive accepts and displays an integer value
converted to a character"/.
Yet, with Scilab 6.1.0
--> msprintf("AB %c\n", 3)
msprintf: Wrong number of input arguments: data doesn't fit with format.
--> mprintf("AB %c\n", "5")
AB 5
--> mprintf("AB %c\n", "R")
AB R
--> mprintf("AB %c\n", "RB")
AB RB
So, what's the difference between the %c and %s printing formats?
The Scilab 5.5 behavior was the same, except that only the first
character of the input was printed:
-->msprintf("AB %c\n", "RB")
ans =
AB R
Regards
Samuel
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.scilab.org/pipermail/users/attachments/20201021/992d5f47/attachment.htm>
More information about the users
mailing list