Record Detail

Accepted

prepare (1/2): 
finished

make (2/2): 
gcc -Wall -O2 -lm   -c -o main.o main.c
main.c: In function 'main':
main.c:31:5: warning: implicit declaration of function 'srand'; did you mean 'scanf'? [-Wimplicit-function-declaration]
     srand(time(NULL));
     ^~~~~
     scanf
main.c:51:30: warning: implicit declaration of function 'rand' [-Wimplicit-function-declaration]
                 printf("%x", rand() % 16);
                              ^~~~
main.c:57:16: warning: suggest parentheses around comparison in operand of '&' [-Wparentheses]
         if (en != 0 & ke != 0)
             ~~~^~~~
main.c:62:30: warning: implicit declaration of function 'ceil' [-Wimplicit-function-declaration]
             int turns = (int)ceil(cipher_len / 8.0);
                              ^~~~
main.c:62:30: warning: incompatible implicit declaration of built-in function 'ceil'
main.c:62:30: note: include '<math.h>' or provide a declaration of 'ceil'
main.c:101:30: warning: incompatible implicit declaration of built-in function 'ceil'
             int turns = (int)ceil(cipher_len / 16.0);
                              ^~~~
main.c:101:30: note: include '<math.h>' or provide a declaration of 'ceil'
main.c:135:37: warning: implicit declaration of function 'strtol'; did you mean 'strtok'? [-Wimplicit-function-declaration]
                 plain[i] = (uint8_t)strtol(temp, NULL, 16);
                                     ^~~~~~
                                     strtok
main.c:104:18: warning: unused variable 'ch' [-Wunused-variable]
             char ch;
                  ^~
main.c:164:26: warning: incompatible implicit declaration of built-in function 'ceil'
         int turns = (int)ceil(cipher_len / 8.0);
                          ^~~~
main.c:164:26: note: include '<math.h>' or provide a declaration of 'ceil'
main.c:200:26: warning: incompatible implicit declaration of built-in function 'ceil'
         int turns = (int)ceil(cipher_len / 16.0);
                          ^~~~
main.c:200:26: note: include '<math.h>' or provide a declaration of 'ceil'
main.c:25:23: warning: unused variable 't' [-Wunused-variable]
     uint8_t temp[64], t;
                       ^
main.c:25:13: warning: unused variable 'temp' [-Wunused-variable]
     uint8_t temp[64], t;
             ^~~~
main.c:24:13: warning: unused variable 'aroundkey' [-Wunused-variable]
     uint8_t aroundkey[176] = {0};
             ^~~~~~~~~
gcc -o c2 main.o -Wall -O2 -lm
make clean
make[1]: Entering directory '/out'
rm -f *.o result
make[1]: Leaving directory '/out'
finished

all tasks finished, build successfully
# Status Time Cost Memory Cost
#1 Accepted Detail 33ms 5.633 MiB

Information

Submit By
Type
Submission
Homework
Challange 2
Language
GNU Make
Submit At
2019-07-07 19:35:35
Judged At
2019-07-07 19:35:35
Judged By
Score
100
Total Time
33ms
Peak Memory
5.633 MiB