Código em C do programa para fazer uma pegadinha
Autor: Guilherme Afonso | Publicado: 2016-03-26T12:50:00-03:00

O programa gerado pelo código serve para você fazer uma pegadinha com seu amigo, nele você deve pedir a pessoa para fazer uma pergunta, ex: "Qual a cor da minha camisa" se a camisa for Amarela, você finge que está escrevendo "Oh Grande Shen-Long, mas você deve ir digitando Amarela, pois cada vez que você tecla uma letra aparece outra na tela dessa forma, ao invés de aparecer "Amarela" na tela, vai aparecer "Oh Gran", quando você terminar de digitar Amarela aperte "." pois aí o programa vai entender que você terminou a resposta, nesse momento vai estar na tela "Oh Grand", dai em diante você deve terminar de digitar a frase "Oh grande Shen-long" só para disfarçar, e assim que você terminar use a vírgula, e então digite a pergunta "Qual a cor da camisa do meu amigo?" quando você apertar a interrogação o programa automaticamente vai mostrar a resposta que no caso é "Amarela". Tente usar o programa, qualquer dúvida pergunte nos comentários!


#include &lt;stdlib.h&gt;
#include &lt;stdio.h&gt;
#include &lt;conio.h&gt;
#include &lt;windows.h&gt;

int main()
{
int i, j;
char resposta[100], pergunta[100];
char shen[]="Oh Grande Sheng-Long,";

system("color 02");
printf("                                        ,   ,  \n");
printf("                                        $,  $,     ,            \n");
printf("                                         ss.$ss. .s'     \n");
printf("                                ,     .ss$$$$$$$$$$s,              \n");
printf("                                $. s$$$$$$$$$$$$$$`$$Ss       \n");
printf("                                 $$$$$$$$$$$$$$$$$$o$$$       ,       \n");
printf("                               s$$$$$$$$$$$$$$$$$$$$$$$$s,  ,s  \n");
printf("                              s$$$$$$$$$ $$$$$$´´´´$$$$$$ $$$$$,     \n");
printf("                              s$$$$$$$$$$s  $$$$ssssss $$$$$$$$    \n");
printf("                             s$$$$$$$$$$          ````ss $ $s       \n");
printf("                             s$$$$$$$$$$,              `´`´`´$  .s$$s\n");
printf("                             s$$$$$$$$$$$$s,...               `s$$'  `\n");
printf("                         `ssss$$$$$$$$$$$$$$$$$$$$####s.     .$$´$.   , s-\n");
printf("                           `````$$$$$$$$$$$$$$$$$$$$#####$$$$$$      $.$ \n");
printf("                                  $$$$$$$$$$$$$$$$$$$$$####s       .$$$|\n");
printf("                                   $$$$$$$$$$$$$$$$$$$$$$$$##s    .$$  $ \n");
printf("                                   $$  $$$$$$$$$$$$$$$$$$$$$$$$$$$$$    `\n");
printf("                                  $$    $ $$$$$$$$$$$$$$$$$$$$S´`´`´ \n");
printf("                             ,   ,´        $$$$$$$$$$$$$$$$####s  \n");
printf("                             $.          .s$$$$$$$$$$$$$$$$$#### \n");
printf("                 ,            $s.   ..ssS$$$$$$$$$$$$$$$$$$$#### \n");
printf("                 $           .$$$S$$$$$$$$$$$$$$$$$$$$$$$$##### \n");
printf("                 Ss     ..sS$$$$$$$$$$$$$$$$$$$$$$$$$$$######\n");
printf("                   $$sS$$$$$$$$$$$$$$$$$$$$$$$$$$$######## \n");
printf("           ,      s$$$$$$$$$$$$$$$$$$$$$$$$#########\n");
printf("           $    s$$$$$$$$$$$$$$$$$$$$$#######         s          ,\n");
printf("           $$..$$$$$$$$$$$$$$$$$$######         ....,$$....    ,$\n");
printf("             $$$$$$$$$$$$$$$######`´ ,     .sS$$$$$$$$$$$$$$$$s$$\n");
printf("              $$$$$$$$$$$$#####      $, .s$$$$$$$$$$$$$$$$$$$$$$$$s.\n");
printf("   )          $$$$$$$$$$$#####       `$$$$$$$$$###########$$$$$$$$$$$.\n");
printf("  ((          $$$$$$$$$$$#####       $$$$$$$$###         ####$$$$$$$$$$ \n");
printf("  ) \         $$$$$$$$$$$$####.     $$$$$$###               ###$$$$$$$$$   s \n");
printf(" (   )        $$$$$$$$$$$$$####.   $$$$$###                 ####$$$$$$$$s$$ \n");
printf(" )  ( (       $$ $$$$$$$$$$$#####.$$$$$###  -              .###$$$$$$$$$$ \n");
printf(" (  )  )   _,$    $$$$$$$$$$$$######.$$##                 .###$$$$$$$$$$\n");
printf(" ) (  ( \.          $$$$$$$$$$$$$#######,,,.          ..####$$$$$$$$$$$ \n");
printf("(   )$ )  )        ,$$$$$$$$$$$$$$$$$$####################$$$$$$$$$$$        \n");
printf("(   ($$  ( \     _sS   ` $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$S$$,       \n");
printf(" )  )$$$s ) )  .      .   `$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$    `$$   \n");
printf("  (   $$$Ss/  .$,    .$,,s$$$$$$##S$$$$$$$$$$$$$$$$$$$$$$$$S            \n");
printf("    \)_$$$$$$$$$$$$$$$$$$$$$$$##   $$        `$$.        `$$.\n");
printf("        ` S$$$$$$$$$$$$$$$$$#       $          `$          `$\n");
printf("            `´`´`´`´`´`´`´`         `           `           `\n\n\n");
printf("Bem vindo ao templo do Grande Sheng-Long! Faca sua pergunta, mero mortal:\n");

for(i=0;i<=100;i++){
    resposta[i]=getch();
    if(resposta[i]=='.'){
        do{
            printf("%c", shen[i]);
            resposta[i]=getch();
            if(resposta[i]==','){
                j=i;
                resposta[i]=' ';
                break;
            }
            resposta[i]=' ';
            i++;
        }while(resposta[i]!=',');
        printf("%c", shen[i+1]);
        break;
    }
    printf("%c", shen[i]);
}
for(i=0;i<=100;i++){
    pergunta[i]=getch();
    if(pergunta[i]=='?'){
        break;
    }
    printf("%c", pergunta[i]);
}
printf("?");
printf("\n");
for(i=0;i<=j;i++)
    printf("%c", resposta[i]);
printf("\n");

system("PAUSE");
return 0;
}