Welcius

P97156: Nombres en un interval

Jan 22nd, 2015
875
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.20 KB | None | 0 0
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. int main() {
  5.     int a, b;
  6.     cin >> a >> b;
  7.     if (a <= b) cout << a;
  8.     for(int i=a+1;i<=b;++i) {
  9.         cout << "," << i;
  10.     }
  11.     cout << endl;
  12. }
Advertisement
Add Comment
Please, Sign In to add comment