Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- using namespace std;
- typedef struct BIT
- {
- bool bit[8];
- bool klucz[10];
- unsigned char klucz[0]: 1;
- void zamiana(unsigned char c)
- {
- bit[0] = (c >> 7) % 2;
- bit[1] = (c >> 6) % 2;
- bit[2] = (c >> 5) % 2;
- bit[3] = (c >> 4) % 2;
- bit[4] = (c >> 3) % 2;
- bit[5] = (c >> 2) % 2;
- bit[6] = (c >> 1) % 2;
- bit[7] = c % 2;
- }
- }text;
- int main()
- {
- unsigned char tekst;
- cin >> tekst;
- zamiana(tekst);
- system("pause");
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement