Hello,
I have one little problem. How connect integer together?
example:
int n = 1
int m = 1
int k = 1
result = n + m + k //but result should be 111 not 3(also keep it like integer)
little trick but not working for me... thanks for help))
This is a discussion on Connecting intervals together within the C++ Programming forums, part of the General Programming Boards category; Hello, I have one little problem. How connect integer together? example: int n = 1 int m = 1 int ...
Hello,
I have one little problem. How connect integer together?
example:
int n = 1
int m = 1
int k = 1
result = n + m + k //but result should be 111 not 3(also keep it like integer)
little trick but not working for me... thanks for help))
Last edited by kaspari22; 06-24-2011 at 08:17 AM.
I don't know what you mean by "keep it like interval" (EDIT: unless you mean integer instead). As to how to build 111, ask yourself: what does the first 1 mean, what does the second 1 mean, and what does the third 1 mean?
Sorry my mistake all of them should be Integer...
are all these numbers <10?
if not, what is the desired output then?
Yes it should be only one type 0-9 so <10
here's a hint:
100 +
010 +
001