Advertisement
gtw7375

Questão 7 - Portugal

Sep 10th, 2014
234
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 0.39 KB | None | 0 0
  1. #include <stdio.h>
  2. #include <conio.h>
  3.  
  4. main() {
  5.    
  6.     float anos, ze, chico;
  7.    
  8.         printf("Digite o numero de anos");
  9.         scanf("%f", &anos);
  10.        
  11.        
  12.         ze = 1.10 + (0.03*anos);
  13.         chico = 1.50 + (0.02*anos);
  14.        
  15.         if(ze > chico) {
  16.            
  17.             printf("%f \n Ze e maior que Chico", ze );
  18.         } else {
  19.             printf("%f \n Chico ainda é maior que Ze", chico );
  20.         }
  21.        
  22.        
  23.         getch();
  24.         return 0;
  25.  
  26. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement