Skip to content

Instantly share code, notes, and snippets.

@kainio
Forked from flpsaad/exercice9.c
Created December 19, 2018 22:25
Show Gist options
  • Save kainio/74ca8b72ceca533821e5e91a1aad59c7 to your computer and use it in GitHub Desktop.
Save kainio/74ca8b72ceca533821e5e91a1aad59c7 to your computer and use it in GitHub Desktop.
titre.prénom.soyez bienvenu
#include<stdio.h>
#include<stdlib.h>
#include<string.h>
int main()
{
char prenom[20];
char titre[10];
printf("entrez votre prenom: ");
scanf("%s",&prenom);
printf("entrez votre titre: ");
scanf("%s",&titre);
if(strcmp(titre,"Mr"))
{
printf("%s %s, soyez le bienvenu ", titre,prenom);
}else{
printf("%s %s, soyez la bienvenue", titre,prenom);
}
return 0;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment