| 12
 3
 4
 5
 6
 7
 8
 9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 
 |  
 #include <unistd.h>
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
 
char c [30];
char d [30];
 
const char password [] = "entrer";
const char username [] = "" ;
 
int main()
{
    printf("veuillez afficher le username et trouver le mot de passe\n");
    printf("username : ");
    scanf("%s", c);
    strcmp(c, username);
    printf("password : ");
    scanf("%s", d);
    strcmp(d, password);
 
    if(d == "entrer")
        printf("access accepté\n");
    else
        printf("access refusé\n");
 
    return 0;
} | 
Partager