mardi 1 décembre 2015

C# Doing a 2 dimension matrix with randoms numbers between 10 and 25

It may seems ridiculous or like I didn't even try, but trust me I did.

all I can do is this:

        float[,] notes = new float[6, 3];
        int l, c;

after that am lost trying things like this

        for (l = 0; l <= notes.GetUpperBound(0); l++)
        {
            for (c = 0; c <= notes.GetUpperBound(1); c++)
            {
                Console.Write("{0,5}   ", notes[l, c]);
            }
            Console.WriteLine();
        }
        Console.ReadLine();

But not much is working here. Not to mention am not even sure how to incorporate the randomizer in this... also it needs to count odd numbers in each columns.

So I need guidance of what to do and who to do it this way.




Aucun commentaire:

Enregistrer un commentaire