User Tools

Site Tools


c:stdio.h:vsscanf
click
to support this page (eg 0,42 € or so) Thanks.

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

c:stdio.h:vsscanf [2013/02/03 19:11]
127.0.0.1 external edit
c:stdio.h:vsscanf [2013/02/25 16:27] (current)
158.181.88.241
Line 1: Line 1:
 ====== vsscanf ====== ====== vsscanf ======
 <code c> <code c>
 +int vsscanf(const char *restrict s, const char *restrict format, va_list arg);
 </code> </code>
  
 ==== description of vsscanf ==== ==== description of vsscanf ====
-vsscanf is in work by code-reference.com \\  +The vscanf(), vfscanf(), and vsscanf() functions shall be equivalent to the scanf(), fscanf(), and sscanf() functions, respectively, except that instead of being called with a variable number of arguments, they are called with an argument list as defined in the <stdarg.h> headerThese functions shall not invoke the va_end macroAs these functions invoke the va_arg macro, the value of ap after the return is unspecified.
-if you are faster... don't hasitate and add it+
  
 <code c> <code c>
-no example at the moment+#include <stdio.h> 
 +#include <stdarg.h> 
 + 
 +char buffer[80] = "6 7.0 hoopy"; 
 + 
 +int my_vfscanf(char *fmt, ...) 
 +
 +   va_list  argptr; 
 +   int cnt; 
 + 
 +   fflush(stdin); 
 + 
 +   va_start(argptr, fmt); 
 +   cnt = vsscanf(buffer, fmt, argptr); 
 +   va_end(argptr); 
 + 
 +   return(cnt); 
 +
 + 
 + 
 +int main(void) 
 +
 +   int inumber; 
 +   float fnumber; 
 +   char string[80]; 
 + 
 +   my_vfscanf("%d %f %s", &inumber, &fnumber, string); 
 +   printf("%d * %f = %s\n", inumber, fnumber, string); 
 +   return 0; 
 +}
 </code> </code>
  
 ===== output of vsscanf c example ===== ===== output of vsscanf c example =====
-    no example at the moment+    6 * 7.000000 = hoopy
  
advertising
c/stdio.h/vsscanf.txt · Last modified: 2013/02/25 16:27 by 158.181.88.241

Impressum