Sum grades Groovy coding questions & answers

Q1. Given the following grades, can you write Groovy code to sum the grades? A1. inject(0) initializes the result to 0. Each grade is then added to the result. The inject is an enhanced method on the GDK (Groovy Development…


Java Interview FAQs

800+ Java Interview Q&As

Top