The code editor available in the HackerRank Tests has an intellisense-like-autocomplete feature similar to what is found in modern editors such as Eclipse or Visual Studio. While typing code in HackerRank Tests, this feature allows Candidates to speed up their coding and reduces the keyboard input time using auto-completion syntax popups. It also hints at any syntax errors beforehand and saves the Candidates' time involved in fixing compilation issues.
Click here to know about the auto-complete capability in the IDE for Front-end, Back-end, and Full-stack project type Questions.
Code auto-complete for Coding Questions
For example, while coding in Python, when you type Sys. , you will see the different syntax suggestions in the auto-complete popup menu as shown below. You can choose from the available suggestions and adopt it by typing the Tab or Enter key.
With auto-complete enabled the editor identifies and underlines incorrect syntax which can result in compilation errors. Hover your mouse over the code, and a tool-tip describes the error. You can fix these errors early and save time in your Test.
In your coding Tests, click the icon and Enable/Disable the auto-complete feature as required. While typing your code in the editor:
- Press CTRL + Space key to trigger the auto-complete popup menu manually.
- Press the Esc key to ignore the popup menu suggestions.
Note: The code auto-completion capability is available in your HackerRank coding Tests only if it is permitted by your test setter.
In the IDE, press CTRL + SPACE to trigger the auto-complete popup menu, and press TAB to add the top suggestion.