Best Practices Guide for Data Structure Visualization Tool

This tool aims to dynamically visualize the changes in common data structures within code through graphical representations, step-by-step showcasing the creation, modification, and manipulation processes of data structures. It is suitable for algorithm learning and debugging scenarios.

Due to the inherent nature of visualization, please note the following points when writing code and using this tool for visualization to ensure a better experience:

  1. Not Recommended

    • Avoid including print statements in your code. The tool automatically records variable changes during execution; therefore, print statements will have no effect on the visualization.
    • Avoid using complex custom data structures. While they might execute correctly, they often won't yield ideal visualization results. The website will continue to be updated to support more data structures.
    • Given the differences and complexities between programming languages, the website's support for language syntax is also continuously improving. Using unsupported syntax may prevent the proper display of data structure changes or even cause errors. Syntax support details for each language will be documented in its respective language-specific documentation.
  2. Not Supported

    • External data input is not supported. You must explicitly create data and call algorithms within your code.
    • Manual inclusion of header files, import packages, etc., is not supported. Common algorithm libraries for each language have been pre-imported.

Common Errors

  1. CODE_PARSE_ERROR | CODE_EXEC_ERROR
    • The code itself contains errors. If your code runs locally, then another issue exists.
    • Syntax not supported by this tool was used. Please refer to the language-specific support documentation for details.
  2. STEP_NONE
    • Your code did not execute any steps (e.g., only defined functions or classes but didn't call them).
  3. STEP_EXCEED
    • The step count exceeds the limit. Please reduce the input size of your code.