In Java, strings have a charAt() function.
In C++, that function is simply stringname[INDEX]
However, what if I wanted to use a particular number at a certain index of an integer?
E.g.
int value = 9123;
Let’s say I wanted to work with the index 0, which is just the 9.
Is there a way to use index at’s with integers?
You can use the following formula (pseudo-code) :