Skip to content

Error in "return" reference page example code #6562

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
RicardoGlobal opened this issue Jul 27, 2017 · 1 comment · Fixed by arduino/reference-en#200
Closed

Error in "return" reference page example code #6562

RicardoGlobal opened this issue Jul 27, 2017 · 1 comment · Fixed by arduino/reference-en#200
Labels
Component: Documentation Related to Arduino's documentation content Type: Bug

Comments

@RicardoGlobal
Copy link

RicardoGlobal commented Jul 27, 2017

In the webpage https://www.arduino.cc/en/Reference/Return, in the code example there is an error:
it says:

int checkSensor(){       
    if (analogRead(0) > 400) {
        return 1;
    else{
        return 0;
    }
}

there is a } missing just before the else.
It is obvious for programmers but could turn out to be a nightmare for novices.

@per1234 per1234 changed the title Documentation error Error in "return" reference page example code Jul 27, 2017
@per1234 per1234 added Component: Documentation Related to Arduino's documentation content Type: Bug labels Jul 27, 2017
@per1234
Copy link
Collaborator

per1234 commented Nov 9, 2017

Closed by arduino/reference-en#200

@per1234 per1234 closed this as completed Nov 9, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Component: Documentation Related to Arduino's documentation content Type: Bug
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants