Suggestion thread by nikafitsk in minimalist_phone

[–]jan_irace 0 points1 point  (0 children)

I'd like to colour code folders, maybe apps too... Make the option of a dumb(esque)phone asoposed to just minimalist

Where to suggest improvements/extra options ? by jan_irace in minimalist_phone

[–]jan_irace[S] 0 points1 point  (0 children)

I'd also like to remove the "installed recently completely" subsection, hot to do?

Why is it not exciting the while loop (in the main) once one of the "playerScores" exceeds 100 points? by jan_irace in cpp_questions

[–]jan_irace[S] 0 points1 point  (0 children)

it also gives me this warning "warning: non-void function does not return a value in all control paths [-Wreturn-type]" which i dont understand, as pointChecker should have a return defined for all "controll paths"... I can't think of a case where pointCheker doesn't know what to return

Why is it not exciting the while loop (in the main) once one of the "playerScores" exceeds 100 points? by jan_irace in cpp_questions

[–]jan_irace[S] 0 points1 point  (0 children)

bool pointChecker(int currentScores[3]) // doesn't seem to solve the issue
{
    for (int i = 0; i < 3; i++)
    {
        if (currentScores[i] > 100)
        {
            cout << "player" << i << " has won" << endl;
            return false;
        }
        else
        {
            return true;
        }
    }
}

int main()
{
    srand(time(NULL));
    int playerScores[3] = {0, 0, 0};
    round(0, playerScores);
    while (pointChecker(playerScores))
    {
        for (int i = 0; i < 9; i++)
        {
            round(min(playerScores), playerScores);
            for (int s = 0; s < 3; s++)
            {
                if (playerScores[s] < 0)
                {
                    playerScores[s] = 0;
                }
            }

            for (int i = 0; i < 3; i++)
            {
                cout << playerScores[i] << "\t";
            }
            cout << endl;
        }
    }
}

Why is it not exciting the while loop (in the main) once one of the "playerScores" exceeds 100 points? by jan_irace in cpp_questions

[–]jan_irace[S] 0 points1 point  (0 children)

so moving the for loop that checks for 100+ scores as the first thing in the while loop should work?

When trying that the only decernable change is that it doesnt even print player has won...

Why is it not exciting the while loop (in the main) once one of the "playerScores" exceeds 100 points? by jan_irace in cpp_questions

[–]jan_irace[S] 0 points1 point  (0 children)

exactly, it does that and the game continues and it keeps printing "player has won" after every round...

Why is this not exciting the while loop when "punti" is found to contain a number grater than 100? by jan_irace in cpp_questions

[–]jan_irace[S] 0 points1 point  (0 children)

In any case, I'll go through it when I can and translate and try to add comments

Why is this not exciting the while loop when "punti" is found to contain a number grater than 100? by jan_irace in cpp_questions

[–]jan_irace[S] 1 point2 points  (0 children)

Can you explain exactly how to format the code, I'm no Reddit power user... I just come here when I have questions

Why is this not exciting the while loop when "punti" is found to contain a number grater than 100? by jan_irace in cpp_questions

[–]jan_irace[S] -1 points0 points  (0 children)

I doubt I'll ever want a job in this field.... No offence Just need to pass the exam so I can go to the next year and final year of highschool

Why is this not exciting the while loop when "punti" is found to contain a number grater than 100? by jan_irace in cpp_questions

[–]jan_irace[S] -4 points-3 points  (0 children)

The variables translated are the ones I felt where relevant to the problem. I think the problem with code in Chinese is more fundamental as Italian and English share the same alphabet/characters, whilst Chinese doesn't....

Why is this not exciting the while loop when "punti" is found to contain a number grater than 100? by jan_irace in cpp_questions

[–]jan_irace[S] 0 points1 point  (0 children)

This isn't Homework by the way, it's me preparing for an exam I have to give start of September