zoukankan      html  css  js  c++  java
  • Hand Tracing Code

    1. What dose it mean?

    Hand-tracing is a simulation of code execution in which you step through instructions and track the values of the variables

    2. How do you do it?


    When you hand-trace code or pseudocode, you write the names of the variables on a sheet of paper, mentally execute each step of the code and update the variables.

    It is best to have the code written or printed on a sheet of paper. Use a marker, such as a paper clip, to mark the current line.

    Whenever a variable changes, cross out the old value and write the new value below. When a program produces output, also write down the output in another column.

    3. Example

  • 相关阅读:
    HDU 1058
    Codeforces 349C
    HDU 2602
    HDU 2571
    HDU 2955
    HDU 2084
    HDU 1003
    HDU 1506 & 1505
    POJ 1854
    HDU 2095
  • 原文地址:https://www.cnblogs.com/JasperZhao/p/12898229.html
Copyright © 2011-2022 走看看