當前位置:名人名言大全網 - 短信平臺 - 怎樣實現輸入驗證碼呢?要用C語言的

怎樣實現輸入驗證碼呢?要用C語言的

#include <stdio.h>

#include <string.h>

main()

{

char a[15],i=3;

do{

printf("Password:");

gets(a);

if(strcmp(a,"hello")==0) break;//這裏請連到妳的密碼文件或者是連接到數據庫驗證,這裏是 hello

}while(--i);

if(i==0) printf("Input errer 3 num.System close!\n");

else

{

//這裏寫入妳密碼正確要執行的代碼

}

}