Professional Documents
Culture Documents
Haga Clic para Modificar El Estilo de Subtítulo Del Patrón: Por: Natalia Escolar
Haga Clic para Modificar El Estilo de Subtítulo Del Patrón: Por: Natalia Escolar
ARRAY -Logo
Lo que estamos haciendo en el programa de logo, es hacer que el programa nos ordene 3 nmeros los cuales le pedimos, y para eso hay que usar las siguiente instrucciones, y seguir el diagrama de flujo que esta al final de la presentacin, junto con una foto de cmo quedara el procedimiento para que el programa nos ordene los 3 nmeros que queramos.
2/1/13
MD ARRAY-LOGO
mdarray MDARRAY sizelist mdarray (MDARRAY sizelist origin) Outputs a multi-dimensional array.
EXAMPLE
make "myarray (mdarray [2 3] 0) mdsetitem [0 0] :myarray 1 mdsetitem [0 1] :myarray 2 mdsetitem [0 2] :myarray 3 mdsetitem [1 0] :myarray 4 mdsetitem [1 1] :myarray 5 mdsetitem [1 2] :myarray 6 show :myarray
2/1/13
ARRAY-VISUAL BASIC
The required a list argument is a
comma-delimited list of values that are assigned to the elements of the array contained within the variant.
REMARKS
The notation used to refer to an element of an array consists of the variable name followed by parentheses containing an index number indicating the desired element.
2/1/13
In the following example, the first statement creates a variable named A as a Variant. The second statement assigns an array to variable A. The last statement assigns the value contained in the second array element to another variable
2/1/13
SQUARE ROOT-LOGO
num SQRT num1 Outputs the square root of the input,
of num.
num1:(NUMBER) Number to take
sign of.
2/1/13
EXAMPLE
show sqrt 4
2
show sqrt 9
2/1/13
1 n1 n2 n3 s
n1> n2
Tempi A >N2 N2>N1 TempN N11> B >n3 n3? >N2 No N3>n1 Tempn N1C >n3 2> >n3 n3? N3->n2 N o N2->n3 IMPRIM O F
2/1/13
2/1/13