libc_stdio.pyx 381 Bytes
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
# mode: compile

cimport libc
from libc cimport stdio
from libc.stdio cimport printf, puts, fputs, putchar, fputc, putc, stdout


libc.stdio.printf("hello %s\n", b"world")
stdio.printf("hello %s\n", b"world")
printf("hello %s\n", b"world")
printf("printf_output %d %d\n", 1, 2)
puts("puts_output")
fputs("fputs_output", stdout)
putchar(b'z')
fputc(b'x', stdout)
putc(b'c', stdout)