Last active
February 5, 2016 21:29
-
-
Save rogerioagjr/3a663a961c8c5b4769ba to your computer and use it in GitHub Desktop.
Impedido!
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Impedido! - F2PJ/F2P1 - OBI 2015 | |
// Rogério Júnior | |
// Complexidade: O(1) | |
#include <cstdio> // scanf e printf | |
int main(){ | |
// declaro e leio os valores de l, r e d | |
int l, r, d; | |
scanf("%d %d %d", &l, &r, &d); | |
// se as condições apresentadas no enunciado forem atendidas, imprimo o caractere 'S' | |
if(r>50 && l<r && r>d) printf("S\n"); | |
// caso contrário, imprimo uma linha com o caractere 'N' | |
else printf("N\n"); | |
return 0; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment