Discussions Q&R
#include <iostream>
#include <bitset>
int main()
{
int myDecimalNumber;
std::cin >> myDecimalNumber;
std::string binary = std::bitset<8>(myDecimalNumber).to_string(); //to binary
std::cout<<binary<<"\n";
unsigned long decimal = std::bitset<8>(binary).to_long();
std::cout<<decimal<<"\n";
return 0;
}
2 Votes
5 Réponseshello guys? how are you. i am zeeshan ali from pakistan. i have been in touch with this app for a very long long time. i have found so many friends awesome.. and we do combine study over the internet. anyone of you is interested then join us on facebook by searching this number 03033951255
0 Vote
4 RéponsesEnum,private,finale
4 Votes
4 RéponsesAujourd'hui en vedette
Audio adding
1 Votes
playground input
0 Votes
What is problem in this code
0 Votes
Stuck in Quize
1 Votes
Software developer
0 Votes
C Program
0 Votes
TIPS From Veterans
1 Votes
How I can use div
0 Votes