🙂 İNSANLARIN EN HAYIRLISI INSANLARA FAYDALI OLANDIR 🙂

Burak HABER / C# / İç İçe FOR la tablo oluşturma

1-) C# - İç İçe FOR la tablo oluşturma


using System;

using System.Collections.Generic;

using System.ComponentModel;

using System.Data;

using System.Drawing;

using System.Linq;

using System.Text;

using System.Threading.Tasks;

using System.Windows.Forms;

 

namespace GENEL

{

    public partial class Form1 : Form

    {

        public Form1()

        {

            InitializeComponent();

        }

 

        private void Form1_Load(object sender, EventArgs e)

        {

            int[,] a = new int[3, 5];

 

            for (int i = 0; i < 3; i++)

            {

                for (int j = 0; j < 5; j++)

                {

                    a[i, j] = 70;

                }

            }

 

            for (int i = 0; i < 3; i++)

            {

                for (int j = 0; j < 5; j++)

                {

                    Console.WriteLine(a[i,j]);

                }

            }
    
/*int[,] a = new int[3, 5];

            a[0, 0] = 70;

            a[0, 1] = 70;

            a[0, 2] = 70;

            a[0, 3] = 70;

            a[0, 4] = 70;

            a[1, 0] = 70;

            a[1, 1] = 70;

            a[1, 2] = 70;

            a[1, 3] = 70;

            a[1, 4] = 70;

            a[2, 0] = 70;

            a[2, 1] = 70;

            a[2, 2] = 70;

            a[2, 3] = 70;

            a[2, 4] = 70;

            a[3, 0] = 70;

            a[3, 1] = 70;

            a[3, 2] = 70;

            a[3, 3] = 70;

            a[3, 4] = 70;*/

 

        }

    }

}



NOT

3 SATIR 5 STUN

70

70

70

70

70

70

70

70

70

70

70

70

70

70

70

 

 2021 Mart 11 Perşembe
 401