Jump to content
PiotrekK

jak odczytać liczbę z tablicy i przypisać ją… do zmiennej?

Recommended Posts

jak w temacie. tablica jest wypełniona liczbami 0 i 1 i jak odczytać jedną… z określonej pozycji?

var przodBoh:Number = MojaMapa[myYc][myXc];

<_<

Edited by PiotrekK

Share this post


Link to post
Share on other sites
var tablica:Array = 
//0,1,2,3,4,5,6
[
[1,0,1,1,0,1],//0
[0,0,1,1,1,1] //1
[0,0,1,1,0,0] //2
];
//zmienna przyjmuje wartości true albo false
var zmienna:Boolean = Boolean(tablica[1][1]);

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...

×
×
  • Create New...