TCPサーバの接続情報と、プログラム main.c が与えられた。
main.c は、srand(time(NULL)); を実行した後、数値を読み込み、その数値が rand() の返り値と一致すればflagを出力するというものであった。
そこで、time(NULL)の返り値に適当な値を足したものを srand に渡した後の rand() の返り値を出力する以下のプログラムを用意し、
Information for connecting to a TCP server and a program main.c were given.
What main.c does is reading an integer after executing srand(time(NULL)); and printing the flag if the number read equals to the return value of rand().
Seeing this, I created following program to print the return values of rand() after passing the return value of time(NULL) plus some values to srand,
and executed that on
実行後、時計を見ながら
After executing this program, I connected to the server using