peyzar2᲼᲼
peyzar2᲼᲼
CC#
Created by peyzar2᲼᲼ on 6/8/2023 in #help
First letter gone
Hi, so I made a diamond game, but there is 1 bug which I have no idea where comes from so type random values for width and height for example on both 10 then when you play or just press ESC to finish there is text "Collected diamonds: %" but the C is gone, thanks in advance code: https://pastebin.com/jduMERvNcookieowo
17 replies
CC#
Created by peyzar2᲼᲼ on 11/23/2022 in #help
❔ Using WHILE to sum numbers from 10 until sum == 1000
Hello, how to make using function while () {} to make numbers from 10 to be sum until result is 1000 for example: 10 + 10 (first time) 20 + 11 (2th time) 31 + 12 (3rd time) 43 + 13 (4th time) and etc until result is 1000 also to print the last number after + my broken code:
int i = 10;
int a = 0;

while (i <= 1000)
{
a = a + i;
}

Console.WriteLine(a);
int i = 10;
int a = 0;

while (i <= 1000)
{
a = a + i;
}

Console.WriteLine(a);
8 replies