Skip to main content
CS Teaching Tips

Main navigation

  • Browse All Tips
  • Tags
  • 3D
  • About
  • Rate Tips
  • Tip Sheets

Ensure loops and conditionals are consistently formatted.

  • This will help students to understand the basics of each loop and conditional statement.
  • It will also help students avoid unnecessary refactoring of code later on.

More about this tip

Tags

  • Programming Concepts
External Source

“The ugliest beautiful line of code” (blog post) by Neil Brown

Other Tips By
Other Tips By Neil Brown

Similar tips

Show students what code looks like with and without new programming constructs (e.g., methods, Objects, inheritance, loops, switch statements) to motivate the reasons for using new concepts.
Have students translate between Java Array and ArrayList to highlight the differences between the two.
Use Monopoly, explaining that the game is a class, to demonstrate Java classes and objects in a familiar and interactive way.

For more information or to report a bug, contact us at admin@csteachingtips.org. Built with Bootstrap. Powered by Drupal.

Privacy Policy