**New course!**Every coder should learn

**Generative AI!**

+ 1

# Need help with C# question

Ive been trying to learn the C# way of coding and came across a question in the module 5 quiz of this course that should ve the last question. It deals with: in the word "Sololearn"; x: finding the length, y: finding the index of "e" and then finding the modulus of x%y. The answer is 4 and i cant fugure out how.

3 Answers

+ 2

length is an actual number of letters = 9;
index of 'e' is 5, because indexation begins from "0".
9%5 = 4

+ 2

Sololearn
e is the 6th letter from the left so y=5
It has 9 letters so x=9
9%5=4

0

sorry'