Advertisement
danzylrabago

MultiplicationTable

Mar 25th, 2020
120
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.34 KB | None | 0 0
  1. using System;
  2. class Exercise1 {
  3.  
  4. public static string test(int num) {
  5. int i = 10, k = 1;
  6. int answer;
  7. string ans = "";
  8. do {
  9. answer = num * k;
  10. //cout << num << " x " << k << " = " <<answer<< endl;
  11. ans += (answer).ToString() + " ";
  12. k++;
  13. i--;
  14. } while (i > 0);
  15.  
  16. return ans;
  17. }
  18. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement