Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 825603
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 15, 20262026-05-15T03:16:58+00:00 2026-05-15T03:16:58+00:00

I know that they are used to store data, but I have a difficult

  • 0

I know that they are used to store data, but I have a difficult time understanding exactly how to use them in a program.

In addition, I found this site with a tetris clone tutorial (the actual tutorial is missing). It uses arrays, but I can’t really make sense of how it works.

Here’s an example of the code –

public int[, ,] TShape = new int[4, 4, 2] 
            {
            {{1, 0}, {0, 1}, {1, 1}, {2, 1}}, 
            {{1, 0}, {0, 1}, {1, 1}, {1, 2}}, 
            {{0, 0}, {1, 0}, {2, 0}, {1, 1}}, 
            {{0, 0}, {0, 1}, {1, 1}, {0, 2}}};

Could it be that I’m looking too hard into this, or perhaps there’s something I’m not grasping about it?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-15T03:16:59+00:00Added an answer on May 15, 2026 at 3:16 am

    Imagine you have 10 boxes. Now you want to clearly tell someone which box you are talking about. So you assign numbers to them, from 0 to 9. What you have now is an array of boxes, defined as:

    box[ 10 ]

    The number in the brackets tells you, how many of them are there. By default they are numbered from 0 to 9 (some languages allow to change this, but lets skip that for now). So if you are talking about the fifth box, its box[ 4 ] (since we index from 0!). Now imagine you open the box and see that there are five balls in it. This defines an array:

    box[ 10 ][ 5 ]

    A two dimensional array. How do you tell your friend which ball do you want to talk about? Again, you number them, this time from 0 to 4. How do you specify say the third ball in the seventh box? Simple: box[ 6 ][ 2 ]. And so on. Hope that helps.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I know that such type of questions exist in SF but they are very
I know that there are lots of examples out there on this, but they
I don't have much experience with Utc Dates, but from what I know, they
I know we should store time in UTC in our databases, but I'm having
I know that capture-parenthesed subexpressions is counted in back reference numbering even when they're
I know it is a condition of hard links that they cannot span filesystems.
I'm talking about these . Yeah, I know they are intended to show that
I know that Phonegap has an event for back button, but it's only available
I know that this sort of question has been asked here before, but still
I know that when I use range([start], stop[, step]) or slice([start], stop[, step]) ,

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.