Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- #include <cstring>
- #include <cstdio>
- #include <stdio.h>
- using namespace std;
- void f_encode () {
- cout << "Function for encoding file" << endl;
- }
- void f_decode () {
- cout << "Function for decoding file" << endl;
- }
- int main (int argc, char **argv) {
- if (argv[1] != NULL) {
- if (strcmp(argv[1], "encode") == 0) {
- cout << "Encode mode enabled!" << endl;
- } else {
- if (strcmp(argv[1], "decode") == 0) {
- cout << "Decode mode enabled!" << endl;
- } else {
- cout << "You shall not pass! What the " << argv[1] << "????" << endl;
- }
- }
- } else {
- cout << "What do you mean by saying it..?" << endl;
- }
- if (argv[2] != NULL) {
- FILE * file_object;
- file_object = fopen (argv[2], "r");
- if (file_object != NULL)
- {
- cout << "it`s success!!1111!!11azaza" << endl;
- } else {
- cout << "what the shit?" << endl;
- }
- fclose (file_object);
- }
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement