This file contains hidden or 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
| inteiro = int(input('Digite um inteiro: ')) | |
| potencia = 2 | |
| raiz = 1 | |
| while raiz ** potencia < inteiro: | |
| raiz = raiz + 1 | |
| while raiz ** potencia < inteiro and potencia < 5: | |
| potencia = potencia + 1 | |
| if raiz ** potencia != inteiro: | |
| potencia = 2 |