Help with Magic Number

Here’s the exercise page: https://www.codecademy.com/courses/learn-java/projects/math-magic
-Hi everybody, first of thanks for stopping by! So i decided to challenge myself at Step 11 and created a 2nd number following the Hint sections and got stuck like this:
(Anyhelp or feedback is welcomed and i hope if we can solve this problem, it could help someone else too especially pp like me- beginners. Thanks ya’ll, much love. :smiley:

Code:
int mySecondNumber = 69;
int magicNumber = mySecondNumber * mySecondNumber;
int magicNumber += mySecondNumber;
int magicNumber /= mySecondNumber;
int magicNumber += 17;
int magicNumber -= mySecondNumber;
int magicNumber /= 6;
int FinalNumber = magicNumber;
System.out.println("This is my 2nd magic number " + FinalNumber);

You declared the same variable more than once … which you can’t do in Java.
The first time, you can do int magicNumber,
but every time after that, you should only have magicNumber without the int

2 Likes

Ah shoot, completely gone out of my head that was the same variable ! Now i know thanks to you friend! Brother from another mother you are! Bless ya mate!