# Unit 3-Lesson 17: Score count showing up incorrectly

**URL:** https://forum.code.org/t/unit-3-lesson-17-score-count-showing-up-incorrectly/31497
**Category:** CS Discoveries
**Created:** [October 20, 2019, 1:23am UTC](https://forum.code.org/t/unit-3-lesson-17-score-count-showing-up-incorrectly/31497 "2019-10-20T01:23:51Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![krowe](https://avatars.discourse-cdn.com/v4/letter/k/858c86/32.png) [@krowe](https://forum.code.org/u/krowe)
#### Post date: [October 20, 2019, 1:23am UTC](https://forum.code.org/t/unit-3-lesson-17-score-count-showing-up-incorrectly/31497/1 "2019-10-20T01:23:51Z")

</div>

I have several students creating a score variable in their code.

Example:

BEFORE draw loop:  
var score = 0

IN draw loop (for example):  
text (score, 30, 50)

In Conditional of “ifTouching”  
score = score + 1

Several of these students had the starting score show up as 1 instead of 0. I had another student with the score starting at 4 even though they had the above. Several students even looked at the code of their peers and couldn’t figure out the issue. Thoughts?

---

<div class="post-metadata">

### Author: ![mwood](https://sea2.discourse-cdn.com/flex016/user_avatar/forum.code.org/mwood/32/4941_2.png) [@mwood](https://forum.code.org/u/mwood)
#### Post date: [October 21, 2019, 11:18pm UTC](https://forum.code.org/t/unit-3-lesson-17-score-count-showing-up-incorrectly/31497/2 "2019-10-21T23:18:36Z")

</div>

Generally speaking, this looks like it should work, however, code can run faster than the human eye, so if a collision is taking place early in the loop, the 0 may not be seen before it updates to a higher number. Without seeing a specific example, it’s hard for me to say anything for sure. If you want to post a shared link to one of the projects, I would be happy to look at it.

Mike
