从 wechall.netnet-force.nl 网站,发现网站的内容不错,里面也有不同类型的挑战题目:Javascript / Java Applets / Cryptography / Exploits / Cracking / Programming / Internet / Steganography,有的还有一定的难度。注册了帐号做题,我也从中学到了不少知识。对网络攻防有兴趣的同学可以尝试下。

 

level 601: Keep walking... 
/*
This is a challenge to test your basic programming skills.

Pseudo code:
Set X = 1
Set Y = 1
Set previous answer = 1

answer = X * Y + previous answer + 3

After that => X + 1 and Y + 1 ('answer' becomes 'previous answer') and repeat this till you have X = 525.

The final answer is the value of 'answer' when X = 525. Fill it in below to check if it's the correct answer. If it is, you will get the password for the challenge page.
*/
  第一题是热身题,直接按照题目所说的写代码就行了。

#include <stdio.h>
 
int main()
{
    int answer = 1;
    for(int x = 1, y = 1; x<=525; ++x, ++y)
        answer += (x*y + 3);
    printf("answer: %d\n", answer);
 
    return 0;
}
answer

相关文章:

  • 2021-08-07
  • 2021-06-08
  • 2021-06-19
  • 2021-07-26
  • 2022-01-05
  • 2021-06-15
  • 2022-01-10
  • 2021-12-08
猜你喜欢
  • 2022-01-23
  • 2021-07-31
  • 2021-10-25
  • 2021-12-03
  • 2021-09-27
  • 2022-01-21
  • 2021-09-16
相关资源
相似解决方案