Jump to content



Photo
- - - - -

Multi-dimentional Array!


  • Please log in to reply
7 replies to this topic

#1 saeedkra

saeedkra

    Newbie

  • Members
  • Pip
  • 2 posts

  • Calculators:
    Classpad300

Posted 19 December 2005 - 06:07 PM

How can I define multi-dimentional array in classpad for programming?!
for example how can I have such a table with m row and n col

input n
input m

and then how can I fill the table with m*n cells with "Input" ?!



1 2 3 4 5 ... n
1
2
3
4
5
.
.
.
m

thanks a lot

#2 Overlord

Overlord

    Casio Technician

  • Moderator
  • PipPipPipPipPipPip
  • 355 posts
  • Gender:Male
  • Location:Brussels - Belgium
  • Interests:Math Researcher

  • Calculators:
    My head - C300 OS 3.00 - G100 Rom 1.02 - G65 - G60 - G25

Posted 19 December 2005 - 07:32 PM

fill(0,x,y) creates a new empty array with x rows and y cols
fill(a,x,y) creates a new array with x rows and y cols, filled with values "a"

you can also use [[1,2,3][4,5,6]] to refer to the 2x3 array containing :
[ 1 2 3 ]
[ 4 5 6 ]

#3 saeedkra

saeedkra

    Newbie

  • Members
  • Pip
  • 2 posts

  • Calculators:
    Classpad300

Posted 19 December 2005 - 09:30 PM

thank for your reply
I create a new empty array with 5 rows and 6 cols with fill(0,5,6)
but how can I for example Input "13" for cell in row 4 ,col 3 ?!

#4 MicroPro

MicroPro

    Casio Overlord

  • Deputy
  • PipPipPipPipPipPipPip
  • 640 posts
  • Gender:Male
  • Location:Iran

  • Calculators:
    Casio ClassPad 300

Posted 20 December 2005 - 01:51 PM

Hi,
A very simple solution in 2 Steps:

1. Open your complete PDF ClassPad Manual;
2. Read the section about matrices carefully.
B)

#5 Kilburn

Kilburn

    Casio Technician

  • Members
  • PipPipPipPipPipPip
  • 491 posts
  • Gender:Male
  • Location:France
  • Interests:Blah

  • Calculators:
    FX-7500 G
    ClassPad 300

Posted 20 December 2005 - 02:12 PM

Great! :lol: It's what I always tell in the French forums (all hate reading manuals)

Okay, if you are lazy or tired of reading your manual:

fill(0,5,6)=>array
Input array[4,3]

This is not complicated... ;)

#6 Ata.H.D

Ata.H.D

    Newbie

  • Members
  • Pip
  • 17 posts
  • Gender:Male

  • Calculators:
    fx-cp300
    fx-cp400

Posted 05 July 2015 - 09:31 AM

hi

 

I have

 

1  'array(1,1)

2  'array(1,2)

3  'array(1,3)

4  'array(1,4)

5  'array(1,5)

in array1

I want to do this with array

 

fill(0,1,5)=>array2

fill(0,1,5)=>array1

for i=>j To 5

array1[1,j+1]-array1[1,j-1]=>array2

next

for i=>1 to 5

print array2[1,j]

next

 

but got domain error

 

eg. j=1 for this

array1[1,j+1]-array1[1,j-1]=>array2  means

 

so have

2-??????? ( array[1,0] ) how i can handle this??


Edited by Ata.H.D, 05 July 2015 - 09:32 AM.


#7 Ata.H.D

Ata.H.D

    Newbie

  • Members
  • Pip
  • 17 posts
  • Gender:Male

  • Calculators:
    fx-cp300
    fx-cp400

Posted 05 July 2015 - 02:32 PM

solved like this.

have any idea??

24b8zlu.jpg



#8 Ata.H.D

Ata.H.D

    Newbie

  • Members
  • Pip
  • 17 posts
  • Gender:Male

  • Calculators:
    fx-cp300
    fx-cp400

Posted 06 July 2016 - 08:11 AM

hi

how to get array size ?? eg. fill(0,1,2)⇒array1, so want to show me size 2

 

SOLVED : ColDim(array1)


Edited by Ata.H.D, 06 July 2016 - 09:16 AM.





0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users