New course! Every coder should learn Generative AI!
Try a free lessonQ&A Discussions
How to develop a game
-2 Votes
4 Answers#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 AnswersPlz answer?
1 Vote
2 AnswersWher is mistake?
0 Votes
5 AnswersHot today
Help me plss
4 Votes
Android studio emulator
1 Votes
Return function
1 Votes
Can anyone guide me
0 Votes
Wrong?
0 Votes
Internal vs external JS
1 Votes
Putting files in another folder
1 Votes