Outils pour utilisateurs

Outils du site


tech:langage_c_sans_compiler_-_script_en_c

Langage C sans compiler - Script en C

Classique

hello.c

#include<stdio.h>
 
int main(void)
{
        puts("Hello world !");
        return 0;
 
}
gcc hello.c
./a.out
Hello world !

Autre façon

sudo apt-get install tcc
tcc -run hello.c

Ou encore on peut ajouter un shebang mais le fichier ne sera plus conforme au langage C.

hello.c

#! /usr/bin/tcc -run
 
#include<stdio.h>
 
int main(void)
{
        puts("Hello world !");
        return 0;
 
}
tech/langage_c_sans_compiler_-_script_en_c.txt · Dernière modification : de Jean-Baptiste

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki