Hello this is my first post here, sorry, english is not my first language. Im in the first year of an It education. We work with csharp. In a tet that we had we should produce the following output in a console application: 00–12–34–56–78–9

the loop should look exactly this way: static void Main(string[] args) int i=1; while (i <9)
I’m having mental healh issues this week, an at this moment i can not think clearlly. I would appreciate help from this community, cos in the state that i’m in Iconstantly try to solve this but i’m cannot think clearly because of my medication. thanks a lot for your help
i’d assume it’s something similar to but not exactly:
{ console.writel(i-1); if(i % 2 == 0) console.writel(“–“); i++ }
I think the teacher wrote the — just to seperate the numbers, maybe theres no need to print them .
It was a test where we should do only small changes to existing code. Im in the1 semster. its basically just the numbers from 0-9, but i find no way to generate the output in this particular way
static void Main(string[] args){ int i=1; while (i <9) {Console.WriteLine(“00–12–34–56–78–9”);return;}
🙂
Haha, incredibly funny
Hey Man I just looked in your account, something I rarley do. If you are so incredibly gifted as you describe it there, then maybe you‘re able to produce something better than this very funny „gordian knot“ joke.
C# devs
null reference exceptions

source