<mosaic.cnfolio.com>
PROGRAM
  1. //START
  2.    //INITIALIZE ALL INT VARIABLES TO 0
  3.    //ASK FOR THE USER TO GIVE 2 NUMBER VALUES FOR EACH POKEMON(PIDGEY, RATATA, ZUBAT)
  4.    // For every POKEMON evolvement - you get 1000EXP
  5.    // The Lucky Egg awards twice the EXP - so 2000EXP for every evolvement
  6.    // A Pidgey needs 12 Candies to evolve
  7.    // A Ratata needs 25 Candies to evolve
  8.    // A Zubat needs 50 Candies to evolve
  9.    // IF numberOfEvolvements is greater than numberOfPokemon
  10.       // PRINTF numberOfPokemon
  11.    // ELSE numberOfEvolvements is less or equal than numberOfPokemon
  12.       // PRINTF numberOfEvolvements
  13. //END
  14.  
  15. int main(void)
  16. {
  17.    int numberOfPidgeys = 0;
  18.    int numberOfPidgeyCandies = 0;
  19.    int numberOfRatata = 0;
  20.    int numberOfRatataCandies = 0;
  21.    int numberOfZubat = 0;
  22.    int numberOfZubatCandies = 0;
  23.    
  24.    //pidgey
  25.    printf ( "How many pidgeys do you have?" );
  26.    scanf( "%d", &numberOfPidgeys)
  27.    printf( " - You have entered %d Pidgeys", numberOfPidgeys);
  28.    printf( "\nHow many Pidgey candies do you have in your backbag?");
  29.    scanf( "%d", &numberOfPidgeyCandies );
  30.    printf( " - You have entered %d Pidgey Candies", numberOfPidgeyCandies);
  31.    
  32.    //ratata
  33.    printf ( "\nHow many Ratata do you have?" );
  34.    scanf( "%d", &numberOfRatata)
  35.    printf( " - You have entered %d Ratata", numberOfRatata);
  36.    printf( "\nHow many Ratata candies do you have in your backbag?");
  37.    scanf( "%d", &numberOfRatataCandies );
  38.    printf( " - You have entered %d Ratata Candies", numberOfRatataCandies);
  39.    
  40.    //zubat
  41.    printf ( "\nHow many Zubats do you have?" );
  42.    scanf( "%d", &numberOfZubat)
  43.    printf( " - You have entered %d Zubats", numberOfZubat);
  44.    printf( "\nHow many zubat candies do you have in your backbag?");
  45.    scanf( "%d", &numberOfZubatCandies );
  46.    printf( " - You have entered %d Zubat Candies", numberOfZubatCandies);
  47.    
  48.    
  49.    
  50.    // this is for Pidgey Evolvements
  51.    float numberOfEvolvements = numberOfPidgeyCandies / 12;
  52.    printf( "\n------------RESULT PIDGEYS----------------");
  53.    
  54.    if(numberOfEvolvements >= numberOfPidgeys){
  55.       printf( "\nYou can evolve %d Pidgeys", numberOfPidgeys);
  56.       printf( "\nYou will get %d EXP for evolving %d Pidgeys without Lucky Egg Activated", (numberOfPidgeys * 1000), numberOfPidgeys);
  57.       printf( "\nYou will get %d EXP for evolving %d Pidgeys with Lucky Egg Activated", (numberOfPidgeys * 2000), numberOfPidgeys);
  58.    }
  59.    else{
  60.       printf( "\nYou can evolve %.0f Pidgeys", numberOfEvolvements);
  61.       printf( "\nYou will get %.0f EXP for evolving %.0f Pidgeys without Lucky Egg Activated", (numberOfEvolvements * 1000), numberOfEvolvements);
  62.       printf( "\nYou will get %.0f EXP for evolving %.0f Pidgeys with Lucky Egg Activated", (numberOfEvolvements * 2000), numberOfEvolvements);
  63.    
  64.    }
  65.    
  66.    // this is for Ratata Evolvements
  67.    float numberOfEvolvementsRatata = numberOfRatataCandies / 25;
  68.    printf( "\n------------RESULT RATATA----------------");
  69.    
  70.    if(numberOfEvolvementsRatata >= numberOfRatata){
  71.       printf( "\nYou can evolve %d Ratatas", numberOfRatata);
  72.       printf( "\nYou will get %d EXP for evolving %d Ratata without Lucky Egg Activated", (numberOfRatata * 1000), numberOfRatata);
  73.       printf( "\nYou will get %d EXP for evolving %d Ratata with Lucky Egg Activated", (numberOfRatata * 2000), numberOfRatata);
  74.    }
  75.    else{
  76.       printf( "\nYou can evolve %.0f Pidgeys", numberOfEvolvements);
  77.       printf( "\nYou will get %.0f EXP for evolving %.0f Ratata without Lucky Egg Activated", (numberOfEvolvementsRatata * 1000), numberOfEvolvementsRatata);
  78.       printf( "\nYou will get %.0f EXP for evolving %.0f Ratata with Lucky Egg Activated", (numberOfEvolvementsRatata * 2000), numberOfEvolvementsRatata);
  79.    
  80.    }
  81.    
  82.    // this is for Zubat Evolvements
  83.    float numberOfEvolvementsZubat = numberOfZubatCandies / 50;
  84.    printf( "\n------------RESULT ZUBAT----------------");
  85.    
  86.    if(numberOfEvolvementsZubat >= numberOfZubat){
  87.       printf( "\nYou can evolve %d Zubats", numberOfZubat);
  88.       printf( "\nYou will get %d EXP for evolving %d Zubats without Lucky Egg Activated", (numberOfZubat * 1000), numberOfZubat);
  89.       printf( "\nYou will get %d EXP for evolving %d Zubats with Lucky Egg Activated", (numberOfZubat * 2000), numberOfZubat);
  90.    }
  91.    else{
  92.       printf( "\nYou can evolve %.0f Pidgeys", numberOfEvolvements);
  93.       printf( "\nYou will get %.0f EXP for evolving %.0f Zubats without Lucky Egg Activated", (numberOfEvolvementsZubat * 1000), numberOfEvolvementsZubat);
  94.       printf( "\nYou will get %.0f EXP for evolving %.0f Zubats with Lucky Egg Activated", (numberOfEvolvementsZubat * 2000), numberOfEvolvementsZubat);
  95.    
  96.    }
  97.    
  98.    
  99.    }