Advertisement
Guest User

Untitled

a guest
Dec 13th, 2019
115
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.47 KB | None | 0 0
  1. do{
  2. $x = Read-Host 'Podaj liczbe X: '
  3. $y = Read-Host 'Podaj liczbe Y: '
  4. $w = Read-Host 'Wybierz dzialanie: 1. Dodawanie; 2. Odejmowanie; 3. Mnozenie; 4.Dzielenie: '
  5. if ($w -eq "1"){
  6. [int32]$x + [int32]$y;}
  7.  
  8. if ($w -eq "2"){
  9. [int32]$x - [int32]$y;}
  10.  
  11. if ($w -eq "3"){
  12. [int32]$x * [int32]$y;}
  13.  
  14. if ($w -eq "4"){
  15. [int32]$x / [int32]$y;}
  16.  
  17. $k = Read-Host 'Czy chcesz kontynuowac? t/n'
  18. }while($k -eq "t")
  19. Write-Host "Koniec programu"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement