Need help squashing a simple bug (b=a+b);

By
RainColt
in Programming
in Programming
Go to solution
Solved by RainColt,
3 minutes ago, Fasauceome said:What language is this? Have you tried b+=a?
Its java, basically the same thing as c#.
I haven't but I just solved it. int b = 0; needed to be declared outside of the loop because it reset b back to 0 every time it looped
-
Topics
-
Brxdman ·
Posted in New Builds and Planning4 -
1
-
0
-
0
-
kasdashd ·
Posted in Mobile Gaming1 -
MightyNerdy9 ·
Posted in New Builds and Planning1 -
Cruzzxd ·
Posted in Graphics Cards0 -
0
-
Average_Gamer ·
Posted in Windows4 -
Average_Gamer ·
Posted in CPUs, Motherboards, and Memory3
-
-
play_circle_filled
Latest From Linus Tech Tips:
Even I’M Jealous of These Guys - Reacting to r/HomeLab
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now