Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- using namespace std;
- int concat(int a, int b)
- {
- int c,cnt=0,w,t,h;
- h=b;
- {
- while(h!=0)
- {cnt++;
- c=h%10;
- h=h/10;}
- w=10^cnt;
- t=a*w+h;
- }
- return t;
- }
- int main()
- {
- int k,l;
- cin>>k>>l;
- cout<<concat(k,l);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement