SHARE
TWEET

4_28

a guest Sep 10th, 2018 184 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. algoritmo "4_28"
  2.       declare n1, n2, dividendo, divisor, qd:inteiro;
  3.       declare r:inteiro;
  4.       leia(n1);
  5.       leia(n2);
  6.       dividendo <- n1;
  7.       divisor <- n2;
  8.       qd <- 0;
  9.       enquanto (dividendo - divisor >= 0) faca
  10.                se (dividendo - divisor >= 0) entao
  11.                   qd <- qd + 1;
  12.                fimse
  13.                r <- dividendo - divisor;
  14.                dividendo <- r;
  15.       fimenquanto
  16.       escreval(qd);
  17.       escreval(r);
  18. fimalgoritmo
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Not a member of Pastebin yet?
Sign Up, it unlocks many cool features!
 
Top