diff --git a/cur/programming/1-introduction/unit-1-exam-reference.es.html b/cur/programming/1-introduction/unit-1-exam-reference.es.html new file mode 100644 index 0000000000..efe210e111 --- /dev/null +++ b/cur/programming/1-introduction/unit-1-exam-reference.es.html @@ -0,0 +1,20 @@ + + + + + + + + + + +Unidad 1 Examen AP + + + + +

Unidad 1: Introducción a la programación

+

Laboratorio 2: Conversaciones

+
1.2.2
AAP-3.A.6
En el examen AP no hay un bloque exactamente igual a decir (chisme) o decir (chisme) por (3) segundos ya que no tienen personajes o globos de conversación. En su lugar, la forma correcta de presentar texto al usuario es utilizar, en inglés,
DISPLAY(chisme())
, en el caso que esté escrito como texto, o de la forma un rectángulo blanco con dos palabras, la primera es 'DISPLAY' en mayúsculas y la segunda 'gossip' en minúsculas si está representado como un bloque.

No sería necesario que sepas escribir código utilizando esta notación en el examen AP. Solo debes ser capaz de leerlo para que puedas responder a las preguntas relacionadas con dicha funcionalidad.

1.2.4
1.2.5
AAP-3.E.1
AAP-3.E.2
La expresión número al azar entre (1) y (10) será presentada con la notación en inglés
RANDOM(1, 10)
. Cada vez que se ejecuta este código, vas a obtener un número aleatorio entre 1 y 10.

Laboratorio 3: Arte moderno con polígonos

+
1.3.4
AAP-3.C.1, AAP-2.K.2
La definición del comando personalizado molinete que se muestra a continuación
molinete, ramas: (número de ramas){    repetir(número de ramas)    {        mover (100) pasos        mover (-37) pasos        girar (360 / número de ramas) grados    }}
se escribe en inglés con la siguiente notación
PROCEDURE molinete(numeroDeRamas){    REPEAT numeroDeRamas TIMES    {        mover(100)        mover(-37)        girar_sentidodelreloj(360 / numeroDeRamas)    }}
or PROCEDURE molinete(numeroDeRamas){    REPEAT numeroDeRamas TIMES    {        mover(100)        mover(-37)        girar_sentidodelreloj(360 / numeroDeRamas)    }}
Los procedimientos
mover()
y
girar_sentidodelreloj()
no forman parte del lenguaje AP, por lo que están escrito en minúsculas, de la misma forma que otros procedimientos definidos por el programador.
Ten en cuenta que el bloque sombrero, molinete, ramas: (número de ramas), se escribiría como
PROCEDURE molinete(numeroDeRamas)
. La palabra
procedure
(procedimiento) te indica que la línea de código es como un bloque sombrero; el nombre de la variable entre paréntesis en esa línea es la entrada que toma el procedimiento.
1.3.4
AAP-3.A.5
La siguiente instrucción molinete, ramas: (6) tamaño: (80) respaldo: (20) tendría la siguiente notación
molinete(6, 80, 20)
o un rectángulo blanco que contiene la palabra 'molinete' en mayúsculas seguida de un rectángulo más pequeño que contiene las entradas'6, 80, 20'.

Posiblemente has escuchado que algunas personas utilizan el término "pseudocódigo" para referirse a este pseudo-lenguaje usado en el examen de principios AP CS, pero esto no es pseudocódigo. El pseudocódigo no es un lenguaje de programación, se usa cómo un lenguaje humano natural para describir un algoritmo.

Laboratorio 5: Seguir un objeto

+
1.5.2
AAP-2.K.3
El lenguaje utilizado en el examen AP no permite espacios en los nombres de las entradas (como número de peces) o en los procedimientos definidos por el programador (como ratón y, que no está integrado en su idioma). Así que este ejemplo los traduce a
numPeces
y
ratónY()
.
El motivo de incluir
()
o un cuadro después de
ratónY
se debe a que
ratónY()
es una llamada de procedimiento a pesar de que no toma ninguna entrada.

El guion
repetir hasta que (ratón y < 0) {decir (número de peces)}
se escribiría como

REPEAT UNTIL (ratónY() < 0){    DISPLAY(numPeces)}
o un rectángulo gris con bordes redondeados que contiene todo lo siguiente: en la primera línea, primero las palabras 'REPEAT UNTIL' en mayúsculas y después un rectángulo más pequeño que contiene 'MouseY () < 0' y en la segunda lína un rectángulo blanco con bordes redondeados que contiene en la primera línea la palabra 'DISPLAY' en mayúsculas y luego un rectángulo blanco más pequeño que contiene 'numFish'

Recuerda, no necesitas aprender a escribir el idioma inventado que se usa en el examen AP. Solo tienes que ser capaz de leer y responder preguntas al respecto.

\ No newline at end of file diff --git a/cur/programming/1-introduction/unit-1-exam-reference.html b/cur/programming/1-introduction/unit-1-exam-reference.html new file mode 100644 index 0000000000..328507002c --- /dev/null +++ b/cur/programming/1-introduction/unit-1-exam-reference.html @@ -0,0 +1,20 @@ + + + + + + + + + + +Unit 1 Exam Questions + + + + +

Unit 1: Introduction to Programming

+

Lab 2: Gossip

+
1.2.2
AAP-3.A.6
There is nothing exactly like say (gossip) or say (gossip) for (3) secs on the AP Exam because they don't have sprites and speech balloons, but their way of showing this text to the user is
DISPLAY(gossip())
if it's written as text or a white rounded rectangle containing first the word 'DISPLAY' in all caps and then a smaller white rectangle containing the word 'gossip' in lower case if it's shown as blocks.

You won't have to be able to write code in this notation on the AP exam. You just have to be able to read it so you can answer questions about it.

1.2.4
1.2.5
AAP-3.E.1, AAP-3.E.2
The expression pick random (1) to (10) would be written as
RANDOM(1, 10)
or RANDOM(1, 10). Every time you run this code, you will get a different random number between 1 and 10.

Lab 3: Modern Art with Polygons

+
1.3.4
AAP-3.C.1, AAP-2.K.2
The procedure definition for the custom pinwheel command
pinwheel, branches: (number of branches){    repeat(number of branches)    {        move (100) steps        move (-37) steps        turn clockwise (360 / number of branches) degrees    }}
would be written as
PROCEDURE pinwheel(numberOfBranches){    REPEAT numberOfBranches TIMES    {        move(100)        move(-37)        turn_clockwise(360 / numberOfBranches)    }}
or PROCEDURE pinwheel(numberOfBranches){    REPEAT numberOfBranches TIMES    {        move (100)        move (-37)        turn_clockwise (360 / numberOfBranches)    }}
The procedures
move()
and
turn_clockwise()
aren't built in to the AP's language so they are written in lower case like other programmer-defined procedures.
Notice that the hat block, pinwheel, branches: (number of branches), would be written as
PROCEDURE pinwheel(numberOfBranches)
. The word
PROCEDURE
tells you that that line of the code is like a hat block; the variable name in the parentheses on that line is the input that the procedure takes.
1.3.4
AAP-3.A.5
This instruction setup; pinwheel, branches: (6) size: (80) backup: (20) would be written as
Pinwheel(6, 80, 20)
or a white rounded rectangle containing first the word 'PINWHEEL' in all caps and then a smaller white rectangle containing the inputs '6, 80, 20'.

You may hear people use the term "pseudocode" to refer to this pseudo-language used on the AP CS Principles exam, but it's not pseudocode. Pseudocode isn't a programming language at all, it's the use of normal human language to describe an algorithm.

Lab 5: Follow the Leader

+
1.5.2
AAP-2.K.3
The language used on the AP Exam doesn't allow spaces in names of inputs (such as number of fish) or in programmer-defined procedures (such as mouse y, which isn't built into their language). So this example translates them to
numFish
and
MouseY()
.
The reason for the
()
or box after
MouseY
is that
MouseY()
is a procedure call even though it doesn't take any inputs.

The script
repeat until (mouse y < 0) {say (number of fish)}
would be written as

REPEAT UNTIL(mouseY() < 0){    DISPLAY(numFish)}
or a gray rounded rectangle containing all of the following: on the first line, first the words 'REPEAT UNTIL' in all caps and then a smaller gray rounded rectangle containing 'mouseY () < 0' and on the second line, a white rounded rectangle with a smaller white rounded rectangle inside that contains first the word 'DISPLAY' in all caps and then a smaller white rectangle containing 'numFish'

Remember, you don't need to learn to write the made-up language used on the AP exam. You just have to be able to read and answer questions about it.

\ No newline at end of file diff --git a/cur/programming/1-introduction/unit-1-self-check.es.html b/cur/programming/1-introduction/unit-1-self-check.es.html new file mode 100644 index 0000000000..c3367ac3e8 --- /dev/null +++ b/cur/programming/1-introduction/unit-1-self-check.es.html @@ -0,0 +1,18 @@ + + + + + + + + + + +Unidad 1 Preguntas de Autocomprobacion + + + + +

Unidad 1: Introducción a la programación

+

Laboratorio 2: Conversaciones

+
1.2.3
AAP-2.D
¿Cuál o cuáles de las siguientes cadenas representa un posible resultado de ejecutar el código chisme?
chisme: (reportar (unir (quién) ( ) (hace) ( ) (quién)))
Toma como referencia las siguientes definiciones:
quién definición del bloque reportar: reportar (elemento (aleatorio) de lista (Señora) (Sra. C) (mi gato) (Hannah) (Jake))) hace definición del bloque reportar: reportar (elemento (aleatorio) de lista (lista (escuchó) (ama) (escapó) (ayudó) (está en una banda con)))
Señora y Sra. C ayudaron.
Señora se alejó de mi gato.
Hannah escuchó a Hannah.
Jake ayudó.
1.2.5
AAP-3.E
más complicado quién {    si (número al azar entre (1) y (4)) = (3) {        reportar (unir (quién) (', quién') (hacer) ( ) (quién) (,))    } sino {        reportar (quién)    }} Aproximadamente, ¿con qué frecuencia el código más complicado quién elegirá la respuesta más complicada?
La mitad de las veces
Una tercera parte de las veces
Una cuarta parte de las veces
Tres cuartas partes de las veces
1.2.5
AAP-3.E
más complicado quién {        si (número al azar entre (1) y (4)) = (3) {            reportar (unir (quién) (', quién') (hacer) ( ) (quién) (,))        } sino {            reportar (quién)        }} Aquí se presenta la secuencia de comandos dentro de más complicado quién. ¿Qué cambio a esta secuencia puede hacer que la frase más complicada aparezca más a menudo?
Cambiar el 4 a 5.
Cambiar el 4 a 3.
Cambiar el 3 a 1.
Cambiar el 3 a 5.
1.2.5
AAP-3.E
Haz clic para refrescar los conceptos de números pares e impares.

Un número par es un entero que es divisible entre 2 (tales como 2, 14, 0, -4, -6, -28, y -176).

En contraste, un número impar es un número que no es divisible entre 2 (tales como 1, 3, 9, 17, -5, -33, y -221).

¿Qué expresión va a devolver un número aleatorio par entre 1 y 10?
RANDOM(2, 10)
2 * RANDOM(1, 5)
RANDOM(1, 10) / 2
RANDOM(1, 5)
1.2.5
AAP-3.E
¿Cuál de las siguientes expresiones simula el resultado de lanzar dos dados?
RANDOM(1, 6) + RANDOM(1, 6)
2 * RANDOM(1, 6)
RANDOM(2, 12)
RANDOM(1, 12)
\ No newline at end of file diff --git a/cur/programming/1-introduction/unit-1-self-check.html b/cur/programming/1-introduction/unit-1-self-check.html new file mode 100644 index 0000000000..af8d19207e --- /dev/null +++ b/cur/programming/1-introduction/unit-1-self-check.html @@ -0,0 +1,24 @@ + + + + + + + + + + + + + + + + +Unit 1 Self-Check Questions + + + + +

Unit 1: Introduction to Programming

+

Lab 2: Gossip

+
1.2.3
AAP-2.D
Which two of the following sentences could be reported by gossip?
gossip: (report (join (who) ( ) (does what) ( ) (who)))
For reference:
who reporter block definition: report (item (random) of (list (Señora) (Ms. C) (my cat) (Hannah) (Jake))) does what reporter block definition: report (item (random) of (list (listened to) (loves) (ran away from) (helped) (is in a band with)))
Señora and Ms. C helped.
Señora ran away from my cat.
Hannah listened to Hannah.
Jake helped.
1.2.5
AAP-3.E
more complicated who {    if (pick random (1) to (4)) = (3) {        report (join (who) (', who') (does what) ( ) (who) (,))    } else {        report (who)    }} About how often will more complicated who pick the more complicated choice?
Half the time
A third of the time
A quarter of the time
Three quarters of the time
1.2.5
AAP-3.E
more complicated who {    if (pick random (1) to (4)) = (3) {        report (join (who) (', who') (does what) ( ) (who) (,))    } else {        report (who)    }} Here is the script inside more complicated who. What change to this script will make the more complicated phrase appear more often?
Change the 4 to 5.
Change the 4 to 3.
Change the 3 to 1.
Change the 3 to 5.
1.2.5
AAP-3.E
Click for a review of odd and even numbers.

An even number is an integer that is divisible by 2 (such as 2, 14, 0, -4, -6, -28, and -176).

In contrast, odd numbers are integers not divisible by 2 (such as 1, 3, 9, 17, -5, -33, and -221).

Which expression will return a random even number between 1 and 10?
RANDOM(2, 10)
2 * RANDOM(1, 5)
RANDOM(1, 10) / 2
RANDOM(1, 5)
1.2.5
AAP-3.E
Which expression will simulate the rolling of two dice?
RANDOM(1, 6) + RANDOM(1, 6)
2 * RANDOM(1, 6)
RANDOM(2, 12)
RANDOM(1, 12)
\ No newline at end of file diff --git a/cur/programming/1-introduction/unit-1-vocab.es.html b/cur/programming/1-introduction/unit-1-vocab.es.html new file mode 100644 index 0000000000..e750a88892 --- /dev/null +++ b/cur/programming/1-introduction/unit-1-vocab.es.html @@ -0,0 +1,18 @@ + + + + + + + + + + +Unidad 1 Vocabulario + + + + +

Unidad 1: Introducción a la programación

+

Laboratorio 1: El juego de hacer clic en Alonzo

+
1.1.4: Objetos y disfraces

El personaje de Alonzo lleva el nombre de Alonzo Church, uno de los principales contribuyentes a las primeras ciencias de la computación. En este proyecto, hay tres objetos relacionados con Alonzo:

1.1.4

La transparencia (transparency)de una imagen es cuánto puedes ver lo que hay detrás de ella. Por ejemplo, aquí se muestra el objeto de Alonzo con tres transparencias diferentes (que se han configurado usando el bloque de efecto fantasma ).
tres imágenes de Alonzo, con efecto fantasma de 0%, 25% y 50%, sobre una pared de ladrillo

Laboratorio 2: Conversaciones

1.2.3: Listas, cadenas y concatenación
1.2.3

El proceso de probar, buscar problemas y arreglarlos se llama depuración (debugging). Utilizaremos también el término en inglés, debugging, que viene de la palabra "bug" o "error" y representa la acción de buscar errores en nuestro programa.

1.2.4: procedimientos, reporteros y comandos
AAP-3.A.1, AAP-3.A.2

Un procedimiento (procedure) es una secuencia de instrucciones que puede aceptar valores o acciones de entrada y puede reportar un valor como resultado. Los procedimientos pueden recibir un nombre para distinguirlos. Algunos lenguajes de programación los pueden llamar también métodos o funciones. A continuación se presentan dos tipos de procedimientos que ya has visto en Snap!:

1.2.5: expresiones y valores
AAP-2.B.3, AAP-2.B.4

Laboratorio 3: Arte moderno con polígonos

1.3.1: algoritmos y pseudocódigo
AAP-2.A.1, AAP-2.A.2, AAP-2.A.3

Un algoritmo (algorithm)es una secuencia de pasos que usualmente ejecuta una computadora. El algoritmo no requiere estar escrito en un lenguaje de programación en particular, ni siquiera en un lenguaje de programación. Puede ser escrito en nuestro lenguaje natural en la forma de una secuencia de oraciones que realiza una serie de actividades. Se conoce a un algoritmo escrito en lenguaje natural como pseudocódigo (pseudocode). Una vez que se tiene la idea clara de los pasos a ejecutar, el algoritmo puede escribirse en el lenguaje de programación de tu elección.

¿Cuál es el propósito del "pseudocódigo"? "Pseudo" significa, literalmente, "falso o irreal"; ¿Por qué escribir un algoritmo en nuestro lenguaje natural en lugar de uno tan preciso como Snap!? Si fueras a programar utilizando un lenguaje cargado de puntuación, diseñar tu programa en pseudocódigo te ayudaría a enfocarte en las ideas más importantes en lugar de los detalles como los signos de puntuación o un punto y coma. Sin embargo, el pseudocódigo no es tan necesario en un lenguaje como Snap!. Además, el pseudocódigo puede hacer que te hagas ilusiones acerca de lo que es capaz de hacer una computadora (como por ejemplo, "Selecciona los números ganadores para la lotería de mañana; anótalos y compra el billete de lotería" o "Aquí está la melodía; escribe la armonía").
1.3.3: ¿Qué es una entrada? Parámetro vs. Argumento
AAP-3.A.3

Usamos la palabra "entrada" tanto para parámetros (nombre del campo de entrada) y para los argumentos (valor del campo de entrada).
1.3.6: Iteración
AAP-2.J.1

Los científicos de la computación definen una estructura de programa repetitivo como un ciclo, repetición, o iteración (iteration).

AAP-2.K.1

El código puede repetirse por siempre, un número específico de veces (al usar repetir) o bien hasta que una condición específica se cumpla (por ejemplo al usar repetir hasta que, como se presentará en el Laboratorio 5).
repetir (4) (mover (100), girar (90)) repetir hasta que (tocando (líder)?){    apunta hacia (líder)    mover (1) pasos}

Laboratorio 4: Proteger tu privacidad

1.4.1
IOC-2.A.1

Información personal identificable (Personally identifiable information o PII, por sus siglas en inglés) es la información que puede ser usada por otras personas para generar una idea que quién eres y obtener, posiblemente, más información como tu número de seguridad social, edad, raza, número(s) de teléfono, información médica, información financiera o incluso datos biométricos (huella dactilar o escaneo de las facciones de la cara).

Laboratorio 5: Seguir un objeto

1.5.2

Cuando un programa sigue haciendo lo mismo y nunca se detiene, se llama bucle infinito (infinite loop).

1.5.2
CRD-2.B.2, AAP-2.B.2, AAP-2.B.6

Un segmento de código (code segment) es una secuencia de instrucciones conectadas que llevan a cabo una acción determinada, como la que se muestra a la izquierda, que anima una conversación. Las instrucciones en el segmento de código se llevan a cabo en orden, de arriba a abajo.

\ No newline at end of file diff --git a/cur/programming/1-introduction/unit-1-vocab.html b/cur/programming/1-introduction/unit-1-vocab.html new file mode 100644 index 0000000000..79c8a1aaf7 --- /dev/null +++ b/cur/programming/1-introduction/unit-1-vocab.html @@ -0,0 +1,18 @@ + + + + + + + + + + +Unit 1 Vocabulary + + + + +

Unit 1: Introduction to Programming

+

Lab 1: Click Alonzo Game

+
1.1.4: Sprites and Costumes

The Alonzo character is named after Alonzo Church, a major contributor to early computer science. In this project, there are three objects related to Alonzo:

1.1.4

The transparency of an image is how much you can see what's behind it. For example, here is the Alonzo sprite shown with three different transparencies (which have been set using the ghost effect block).
three pictures of Alonzo, with ghost effect 0%, 25%, and 50%, on a background of a brick wall

Lab 2: Gossip

1.2.3: Lists, Strings, and Concatenation
1.2.3

The process of testing, finding problems, and fixing them is called debugging.

1.2.4: Procedures, Reporters, and Commands
AAP-3.A.1, AAP-3.A.2

A procedure is a named sequence of instructions that may take inputs and may report a value. Some languages call procedures methods or functions. Here are two types of procedures you have seen in Snap!:

1.2.5: Expressions and Values
AAP-2.B.3, AAP-2.B.4

Lab 3: Modern Art with Polygons

1.3.1: Algorithm and Pseudocode
AAP-2.A.1, AAP-2.A.2, AAP-2.A.3

An algorithm is a sequence of steps that are usually performed by a computer. The algorithm doesn't have to be written in any particular programming language or even in a programming language at all; you can write your algorithm in English or any other human language. Some people call an algorithm written in human language pseudocode. Once you know the steps that the computer will take, you can code your algorithm in the programming language of your choice.

What's the purpose of "pseudocode"? Why write an algorithm vaguely in English when you could write it precisely in Snap!? If you were programming in a punctuation-heavy language, designing your program in pseudocode would help you focus on the important ideas instead of on details like quotation marks and semicolons. But pseudocode isn't as necessary with a language like Snap!, and pseudocode can make it easy for you to fall into wishful thinking about what the computer is capable of (such as writing "Pick tomorrow's winning lottery numbers" or "Here's the melody; write the harmony").
1.3.3: What's an input? Parameter vs. Argument
AAP-3.A.3

We use the word "input" both for parameters (input names) and for arguments (input values).
1.3.6: Iteration
AAP-2.J.1

Computer scientists describe a repeating program structure as looping, repetition, or iteration.

AAP-2.K.1

The code can be repeated forever, a specific number of times (such as when using repeat), or until something specific happens (such as when using repeat until as you'll see in Lab 5).
repeat (4) (move (100), turn clockwise (90)) repeat until (touching (Leader)?){    point towards (Leader)    move (1) steps}

Lab 4: Protecting Your Privacy

1.4.1
IOC-2.A.1

Personally identifiable information (PII) is information that can let others figure out who you are and possibly get more information like your Social Security number, age, race, phone number(s), medical information, financial information, or biometric data (such as your thumbprint or face scan).

Lab 5: Follow the Leader

1.5.2

When a program keeps running forever, that's called an infinite loop.

1.5.2
CRD-2.B.2, AAP-2.B.2, AAP-2.B.6

A code segment is a sequence of connected instructions that carry out a purposeful action, such as the one pictured on the left, which animates a conversation. The instructions in the code segment are carried out in order, from top to bottom.

\ No newline at end of file diff --git a/cur/programming/2-complexity/unit-2-exam-reference.es.html b/cur/programming/2-complexity/unit-2-exam-reference.es.html new file mode 100644 index 0000000000..e59bbb5b91 --- /dev/null +++ b/cur/programming/2-complexity/unit-2-exam-reference.es.html @@ -0,0 +1,20 @@ + + + + + + + + + + +Unidad 2 Examen AP + + + + +

Unidad 2: Abstracción

+

Laboratorio 1: Juegos

+
2.1.1
AAP-1.B.2
set (secret number) to (7) se escribiría como
númeroSecreto ← 7
o un rectángulo blanco con el texto 'númeroSecreto ← 7'.
2.1.2
El código preguntar (¿Por qué la gallina cruzó la calle?) y esperar; asignar a (respuesta de usuario) el valor (respuesta) se escribiría como
DISPLAY ("¿Por qué la gallina cruzó la calle?")respuestaUsuario ← INPUT()
o un rectángulo blanco que contiene dos pequeños rectángulos blancos: El primero contiene la palabra 'DISPLAY' en mayúsculas seguido de un rectángulo pequeño blanco que contiene el texto '¿Por qué la gallina cruzó la calle?'. El segundo contiene el texto 'respuestaUsuario ← INPUT()'.
AAP-3.A.8, AAP-3.A.9
Observa que el procedimiento
INPUT()
(Entrada) acepta el valor del usuario y devuelve ese valor de entrada, que luego se asigna a la variable
respuestaUsuario
con la
sintaxis. En Snap!, así es cómo respuesta acepta un valor del usuario y lo reporta, y ese reporte es a lo que la computadora asigna la variable respuesta del usuario.
2.1.4
incrementar (puntuación) en (1) (lo que significa asignar a(puntuación) el valor (puntuación+1)) se escribiría como
puntuación ← puntuación + 1
o puntuación ← puntuación + 1.
2.1.5
AAP-2.N.1 viñeta 1
La expresión de lista elemento (2) de (disfraces) se escribiría como
disfraces[2]
o disfraces[2]. Las tres versiones de este código reportarían/devolverían el disfraz de pingüino (si el lenguaje AP tuviera disfraces como tipo de datos):
elemento (2) de (disfraces) reporta una imagen del disfraz de pingüino
2.1.5
AAP-2.N.1 viñeta 7
La expresión longitud de (lista de palabras) se escribiría como
LENGTH(listaPalabras)
o LENGTH(listaPalabras).

Laboratorio 2: Elaboración de listas

+
2.2.1
AAP-1.C.1 segunda oración, AAP-1.D.7
La expresión de lista lista{Señora, Sra. C, mi gato, Hannah, Jake} se escribiría como
[Señora, Sra. C, mi gato, Hannah, Jake]
. Los elementos se colocan en la lista en el orden en que aparecen en el texto: "Señora" tiene el índice 1, "Sra. C" tiene el índice 2, y así sucesivamente.
2.2.1
AAP-1.D.7 viñeta 2
La instrucción de asignación asignar a (lista de la compra) el valor (lista) se escribiría como
listaDeCompras ← []
o listaDeCompras ← [].
AAP-1.D.7 viñeta 1
La instrucción de asignación asignar a (lista de la compra) el valor {manzanas, pan, zanahorias, arroz, pasta} se escribiría como
listaDeCompras ← [manzanas, pan, zanahorias, arroz, pasta]
o listaDeCompras ← [manzanas, pan, zanahorias, arroz, pasta]. (En esta aplicación, deseará que la lista de la compra comience vacía, y luego el usuario agregue o inserte más artículos comestibles de uno en uno.)
2.2.1
AAP-2.N.1 viñeta 4
añadir (tomate) a (lista de la compra) se escribiría como
INSERT(listaDeCompras, 2, "tomate")
o INSERT(listaDeCompras, 2, 'tomate').
añadir (tomate) a (lista de la compra) se escribiría como
APPEND(listaDeCompras, "tomate")
o APPEND(listaDeCompras, 'tomate').
AAP-2.N.1 viñeta 5
2.2.1
AAP-2.N.1 viñeta 6
borrar (2) de (lista de la compra) se escribiría como
REMOVE(listaDeCompras, 2)
o REMOVE(listaDeCompras, 2).
2.2.1
Los elementos de una lista son valores, por lo que puedes usar elemento de en cualquier lugar donde puedas usar cualquier otra expresión. Por ejemplo:
2.2.1

Cuando ejecutas este programa en Snap!, la segunda línea de código asigna a lista de la compra 2 el valor de lista de la compra (es decir, la misma lista, no una copia). Por eso, la tercera línea de código modifica ambas variables:
asignar a (lista de la compra) a (lista(manzana)(plátano))asignar a (lista de la compra 2) el valor (lista de la compra)añadir (zanahoria) a (lista de la compra) visualización de la lista de la compra con los contenidos de la variable: manzana, plátano, zanahoria; y visualización de la lista de la compra 2 con los contenidos de la variable: manzana, plátano, zanahoria

AAP-1.D.7 viñeta 3, AAP-2.N.2
Sin embargo, en el examen, el enunciado
listaDeCompras2 ← listaDeCompras
hace una copia de la lista. Así que al modificar uno de ellos no se modifica el otro.

Las reglas sobre cómo usar las listas y cómo se comportan difieren según el lenguaje de programación que estés usando.

Laboratorio 3: Tomar decisiones

+
2.3.1
AAP-2.E.2
Puedes ver estos cinco operadores relacionales:
=, >, <, ≥, ≤
así como un sexto:
, que significa "distinto a" y reporta falso si las dos entradas son iguales y, de lo contrario, reporta verdadero (si no son iguales). Cuando escribes el bloque de () distinto a () , funcionará así:
(3) distinto a (4) reporta verdadero (3) distinto a(3) reporta falso

Estos seis operadores relacionales reportan un valor booleano (verdadero o falso).

2.3.2
AAP-2.F.1
Los bloques () y (), () o (), y no () aparecerán en inglés como
AND
,
OR
y
NOT
y funcionarán exactamente de la misma manera que lo hacen en Snap!.
2.4.1
Los distintos lenguajes de programación tienen diferentes formas de manejar entradas negativas a la función módulo. Por lo tanto, no verás ningún uso de módulo con un número negativo en el examen.
El operador módulo ("mod", en inglés): la expresion (17) módulo (5) se escribiría en inglés como
17 MOD 5
en el examen. Si ves una expresión con variables como entrada para módulo, tal como
a MOD b
, puedes asumir que a es cero o positivo, y b es estrictamente positivo (porque no se puede dividir por 0).
AAP-2.B.5, AAP-2.C.1, AAP-2.C.2, AAP-2.C.3, AAP-2.C.4
En el examen, puede ver estos cuatro operadores aritméticos:
+
,
-
,
*
,
/
(más, menos, multiplicar, dividir) así como
MOD
. Los operadores aritméticos son parte de la mayoría de los lenguajes de programación. (La mayoría de los lenguajes de texto utilizan
*
en lugar de
×
para la multiplicación porque
×
no está en la mayoría de los teclados, y porque se parece demasiado a la letra x.)
AAP-2.L.2
Orden de operaciones: En un lenguaje de bloques, la anidación de bloques determina el orden de las operaciones. Por ejemplo, en 3 × (5 + 4) puedes ver que el bloque + es una entrada al bloque ×, entonces la expresión significa 3×(5+4). De manera similar, (3 × 5) + 4 significa (3×5)+4. En Snap!, es como si hubiera paréntesis alrededor de todas las operaciones. Pero en lenguajes de texto, puedes escribir
3 * 4 + 5
sin paréntesis, entonces ahí sí necesitas las reglas que aprendiste en la clase de matemáticas (multiplicación antes de la suma, etc.). El operador módulo es como la multiplicación y la división; ocurre antes de la suma y la resta. Así por ejemplo,
7 + 5 MOD 2 - 6
significa
7 + 1 - 6
, que es, por supuesto, 2.
2.4.1
AAP-2.H.2
Los procedimientos
mover()
y
girar_sentidoreloj()
no están integrados en el lenguaje del AP y por eso que se escriben en letras minúsculas al igual que otros procedimientos definidos por un programador.
La expresión condicional si (tamaño> 15) {repetir (4) {mover (tamaño) pasos, girar (90) grados}} se escribiría como
IF(tamaño > 15){    REPEAT 4 TIMES    {        mover(tamaño)        girar_sentidoreloj(90)    }}
o IF(tamaño > 15){    REPEAT 4 TIMES    {        mover(tamaño)        girar_sentidoreloj(90)    }}

Como en Snap!, si la condición (tamaño) > 15 es verdadero, se ejecuta el código dentro de la instrucción si; pero si la condición es falso, el código no se ejecuta.

2.4.3
AAP-3.C.2
Viste la definición de procedimiento para un comando enUnidad 1 Laboratorio 3, Página 4: Modifica tu molinete.
La definición de un reportero se parece mucho a la definición de un comando excepto que incluye un
RETURN
(como reportar). Por ejemplo, esta definición

En muchos lenguajes (incluido Snap!) las variables deben ser declaradas de alguna manera (en Snap!, puedes hacer clic al botón "Crear una variable" o usar el bloque variable de programa). Pero el lenguaje de AP no incluye declaraciones de variables, por eso no los verás en el examen.

raíz cuadrada de (número) {variables de programa (raíz positiva), asignar a (raíz positiva) el valor ((raíz cuadrada) de (número)), reporta (lista (raíz positiva) ((-1) × raíz positiva))
se escribiría como
PROCEDURE raízCuadrada(número){    raízPositiva ← sqrt(número)    RETURN ([raízPositiva, -1 * raízPositiva])}
o PROCEDURE raíz cuadrada (número) (raíz positiva ← raíz cuadrada (número)), RETURN (raíz positiva, -1 * raíz positiva)
AAP-3.A.7
Como con reportar en Snap!, cuando se ejecuta un
RETURN
, el flujo de control vuelve al lugar del código donde se llamó el procedimiento, y el procedimiento devuelve el valor de la expresión dentro del comando
RETURN
o el bloque reportar.
También, el procedimiento
sqrt
(abreviatura de square root, raíz cuadrada en inglés) no está integrado en el lenguaje del AP, es por eso que está escrito en minúsculas como otros procedimientos definidos por un programador.
2.4.3
AAP-2.H.3
La expresión condicional si (a > b) {    reportar verdadero} sino {    reportar (a = b)} se escribiría como
IF(a > b){    RETURN(verdadero)}ELSE{    RETURN(a = b)}
o IF(a > b){    RETURN(verdadero)}ELSE{    RETURN(a = b)}
Como en Snap!, si la condición
a > b
es verdadera, se ejecuta el código en el primer bloque de declaraciones; si es falsa, se ejecuta el código en el segundo bloque de declaraciones.
\ No newline at end of file diff --git a/cur/programming/2-complexity/unit-2-exam-reference.html b/cur/programming/2-complexity/unit-2-exam-reference.html new file mode 100644 index 0000000000..31d6e92f02 --- /dev/null +++ b/cur/programming/2-complexity/unit-2-exam-reference.html @@ -0,0 +1,20 @@ + + + + + + + + + + +Unit 2 Exam Questions + + + + +

Unit 2: Abstraction

+

Lab 1: Games

+
2.1.1
AAP-1.B.2
set (secret number) to (7) would be written as
secretNumber ← 7
or a white rounded rectangle containing the text 'secretNumber ← 7'.
2.1.2
The code ask (Why did the chicken cross the road?) and wait; set (user response) to (answer) would be written as
DISPLAY("Why did the chicken cross the road?")userResponse ← INPUT()
or a white rounded rectangle containing two smaller white rounded rectangles: The first one contains first the word 'DISPLAY' in all caps and then a smaller white rectangle containing the quoted text 'Why did the chicken cross the road?'. The second one contains the text 'userResponse ← INPUT()'.
AAP-3.A.8, AAP-3.A.9
Notice that the procedure
INPUT()
accepts the value from the user and returns that input value, which is then assigned to the variable
userResponse
with the
syntax. In Snap!, this is just like how answer accepts a value from the user and reports it, and that report is what the computer sets the variable user response to.
2.1.4
change (score) by (1) (which means set(score) to (score+1)) would be written as
score ← score + 1
or score ← score + 1.
2.1.5
AAP-2.N.1 bullet 1
The list expression item (2) of (costumes) would be written as
costumes[2]
or costumes[2]. All three versions of this code would report/return the penguin costume (if only the AP language had costumes as a data type):
item (2) of (costumes) reporting a picture of the penguin costume
2.1.5
AAP-2.N.1 bullet 7
The expression length of (words list) would be written as
LENGTH(wordsList)
or LENGTH(wordsList).

Lab 2: Making Lists

+
2.2.1
AAP-1.C.1 second sentence, AAP-1.D.7
The list expression list{Señora, Ms. C, my cat, Hannah, Jake} would be written as
[Señora, Ms. C, my cat, Hannah, Jake]
. The items are positioned in the list in the order they appear in the text: "Señora" has index 1, "Ms. C" has index 2, and so on.
2.2.1
AAP-1.D.7 bullet 2
The assignment instruction set (shopping list) to (list) would be written as
shoppingList ← []
or shoppingList ← [].
AAP-1.D.7 bullet 1
The assignment instruction set (shopping list) to {apples, bread, carrots, rice, pasta} would be written as
shoppingList ← [apples, bread, carrots, rice, pasta]
or shoppingList ← [apples, bread, carrots, rice, pasta]. (In this app, you'll want the shopping list to begin empty, and then the user will add or insert additional grocery items one at a time.)
2.2.1
AAP-2.N.1 bullet 4
insert (tomatoes) at (2) of (shopping list) would be written as
INSERT(shoppingList, 2, "tomatoes")
or INSERT(shoppingList, 2, 'tomatoes').
AAP-2.N.1 bullet 5
add (tomatoes) to (shopping list) would be written as
APPEND(shoppingList, "tomatoes")
or APPEND(shoppingList, 'tomatoes').
2.2.1
AAP-2.N.1 bullet 6
delete item (2) of (shopping list) would be written as
REMOVE(shoppingList, 2)
or REMOVE(shoppingList, 2).
2.2.1
The items in a list are values, so you can use item of anywhere you can use any other expression. For example:
2.2.1

When you run this script in Snap!, the second line of code assigns to shopping list 2 the value of shopping list (that is, the same list, not a copy). So, the third line of code modifies both variables:
set(shopping list) to (list(apple)(banana))set(shopping list 2) to (shopping list)add (carrot) to (shopping list) shopping list watcher showing the contents of the variable to be apple, banana, carrot; and the shopping list 2 watcher showing the contents of the variable to be apple, banana, carrot

AAP-1.D.7 bullet 3, AAP-2.N.2
However on the exam, the statement
shoppingList2 ← shoppingList
makes a copy of the list. So modifying one of them does not modify the other.

The rules for how to use lists and how they behave differ depending on the programming language you are using.

Lab 3: Making Decisions

+
2.3.1
AAP-2.E.2
You may see these five relational operators:
=, >, <, ≥, ≤
as well as a sixth:
, which means "not-equal" and reports false if the two inputs are equal and otherwise reports true (if they are not equal). When you write the () not equal () block, it will work like this:
(3) not equal (4) reporting true (3) not equal (3) reporting false

These six relational operators all report a Boolean value (true or false).

2.3.2
AAP-2.F.1
The () and (), () or (), and not () blocks will appear as
AND
,
OR
, and
NOT
and will work exactly the same way as they do in Snap!.
2.4.1
Different programming languages have different ways of handling negative inputs to the mod function. So you won't see any negative numbers used with mod on the exam.
The mod operator: The expression (17) mod (5) would be written as
17 MOD 5
on the exam. If you see an expression with variables as input to mod, such as
a MOD b
, you can assume that a is zero or positive, and b is strictly positive (because you can't divide by 0).
AAP-2.B.5, AAP-2.C.1, AAP-2.C.2, AAP-2.C.3, AAP-2.C.4
On the exam, you may see these four arithmetic operators:
+
,
-
,
*
,
/
(plus, minus, times, divide) as well as
MOD
. Arithmetic operators are part of most programming languages. (Most text languages use
*
rather than
×
for multiplication because
×
isn't on most keyboards, and because it looks too much like the letter x.)
AAP-2.L.2
Order of operations: In a block language, the nesting of blocks determines the order of operations. For example, in 3 × (5 + 4) you can see that the + block is an input to the × block, so the expression means 3×(5+4). Similarly, (3 × 5) + 4 means (3×5)+4. In Snap!, it's as if there are parentheses around every operation. But in text languages, you can write
3 * 4 + 5
without parentheses, so they need the rules you learn in math class (multiplication before addition, and so on). The mod operator is like multiplication and division; it happens before addition and subtraction. So for example,
7 + 5 MOD 2 - 6
means
7 + 1 - 6
, which is, of course, 2.
2.4.1
AAP-2.H.2
The procedures
move()
and
turn_clockwise()
aren't built in to the AP's language so they are written in lower case like other programmer-defined procedures.
The conditional expression if (size > 15) {repeat (4) {move (size) steps, turn clockwise (90) degrees}} would be written as
IF(size > 15){    REPEAT 4 TIMES    {        move(size)        turn_clockwise(90)    }}
or IF(size > 15){    REPEAT 4 TIMES    {        move(size)        turn clockwise(90)    }}

As in Snap!, if the condition (size) > 15 is true, the code inside the if statement runs; if the condition is false, the code does not run.

2.4.3
AAP-3.C.2
You saw the procedure definition for a command in Unit 1 Lab 3 Page 4: Modify Your Pinwheel.
The definition for a reporter looks much like the definition for a command except that it includes a
RETURN
(like report). For example, this definition

In many languages (including Snap!) variables must be declared in some way (in Snap!, you can click the "Make a variable" button or use the script variables block). But the AP's language doesn't include variable declarations, so you won't see them on the exam.

square roots of (number) {script variables (positive root), set (positive root) to ((sqrt) of (number))), report (list (positive root) ((-1) × positive root))
would be written as
PROCEDURE squareRoots(number){    positiveRoot ← sqrt(number)    RETURN([positiveRoot, -1 * positiveRoot])}
or square roots of (number) {script variables (positive root), set (positive root) to ((sqrt) of (number))), report (list (positive root) (() - positive root))
AAP-3.A.7
As with report in Snap!, when a
RETURN
statement is executed, the flow of control returns to the place in your code where the procedure was called, and the procedure returns the value of the expression inside the
RETURN
command or report block.
Also, the procedure
sqrt
isn't built in to the AP's language so it is written in lower case like other programmer-defined procedures.
2.4.3
AAP-2.H.3
The conditional expression if (a > b) {    report true} else {    report (a = b)} would be written as
IF(a > b){    RETURN(true)}ELSE{    RETURN(a = b)}
or IF(a > b){    RETURN(true)}ELSE{    RETURN(a = b)}
As in Snap!, if the condition
a > b
is true, the code in first block of statements runs; if it is false, the code in second block of statements runs.
\ No newline at end of file diff --git a/cur/programming/2-complexity/unit-2-self-check.es.html b/cur/programming/2-complexity/unit-2-self-check.es.html new file mode 100644 index 0000000000..47559c3fd5 --- /dev/null +++ b/cur/programming/2-complexity/unit-2-self-check.es.html @@ -0,0 +1,19 @@ + + + + + + + + + + +Unidad 2 Preguntas de Autocomprobacion + + + + +

Unidad 2: Abstracción

+

Laboratorio 1: Juegos

+
2.1.1
¿Qué valor mostrará este código?
Ejemplos como este son útiles para probar tu comprensión de la asignación a variables, aunque no usarías una secuencia de asignaciones como esta en un programa real.
a ← 3		b ← a		a ← 4		DISPLAY(b)
3
4
a
b
2.1.1
¿Qué valor reportará este guion?
asignar a m el valor de 9, asignar a k el valor de 5, asignar a m el valor de (m + 1), asignar a k el valor de (k - m), reportar k
-5
3
-4
5
2.1.2
función misteriosa (entrada):si (entrada < 5) (repetir hasta que (entrada = 5)(    decir (entrada) por (1) segs,    asignar a (entrada) el valor (entrada + 1))reportar (terminado) ¿Qué entradas a función misteriosa reportarán "terminado"?
Cualquier número entero
Solo números enteros mayores o iguales a 5
Solo números enteros menores que 5
Solo 5
2.1.2
función misteriosa (entrada):si (entrada < 5) (repetir hasta que (entrada = 5)(    decir (entrada) por (1) segs,    asignar a (entrada) el valor (entrada + 1))reportar (terminado) ¿Qué dirá el personaje si ejecutas la misma función con la entrada 1?
burbuja de texto con un '4'
burbuja de texto con un '5'
cuatro burbujas de texto con un  '1', '2', '3' y '4'
cinco burbujas de texto con un  '1', '2', '3', '4' y '5'
La retroalimentación no ha terminado porque me di cuenta de que BH podría oponerse a cambiar el valor de una variable de entrada... --MF, 3/1/19
2.1.2
función misteriosa (entrada):si (entrada < 5) (repetir hasta que (entrada = 5)(    decir (entrada) por (1) segs,    asignar a (entrada) el valor (entrada + 1))reportar (terminado) ¿Qué sucederá si ejecutas la misma función con la entrada 9?
El personaje dirá 9 y el bloque reportará "terminado".
El personaje dirá 9, 8, 7, 6 y el bloque reportará "terminado".
El personaje dirá 9, 10, 11, 12, 13,... y seguirá contando, y el bloque nunca reportará "terminado".
El personaje no dirá nada y el bloque reportará "terminado".
La retroalimentación no ha terminado porque me di cuenta de que BH podría oponerse a cambiar el valor de una variable de entrada... --MF, 3/1/19
2.1.5

AAP-2.N parte b
¿Cuál de los siguientes bloques reportará una lista de longitud 3?

Elige todos los que correspondan.
lista (piña fresa kiwi)
elemento 3 de {piña, fresa, kiwi}
elemento 2 de {limón, {piña, fresa, kiwi}}
lista () (piña) ()
2.2.2

Imagina que creas una variable mayúsculas y usas conjunto para dar un nombre a esta lista de listas:
asignar a (capitales) el valor {{Augusta, Maine}, {Boise, Idaho}, {Columbia, South Carolina}, {Des Moines, Iowa}}
¿Cuáles de las siguientes afirmaciones son verdaderas?

Elige todos los que correspondan.

elemento (1) de (capitales) reporta una lista con dos elementos: "Augusta" y "Maine".
elemento (1) de (elemento (1) de (capitales)) reporta la palabra "Augusta".
elemento (último) de (elemento (2) de (capitales)) reporta la palabra "Iowa".
(longitud) de (capitales) reporta el número 8.
todos menos el primero de (elemento (último) de (capitales)) reporta la lista con un elemento:"Iowa".
elemento (3) de (capitales) reporta la cadena "Boise".
elemento (último) de (todos menos el primero de (capitales)) reporta la cadena "Iowa".
(longitud) de (elemento (1) de (capitales)) reporta el número 2.
2.2.3

¿Cuál de las siguientes secuencias producirá el siguiente comportamiento de sprite?
sprite saying Abraham then Lincoln
(Sin embargo, cuando ejecutas la secuencia, en realidad dice Abraham Lincoln solo una vez.)

Elige todos los que correspondan.

para cada (elemento) de {Abraham, Lincoln} [decir (elemento) por (1) segs]
decir {Abraham, Lincoln} por (2) segs
decir (elemento (1) de {Abraham Lincoln, George Washington, Barack Obama}) por (2) segs
decir (elemento (1) de {Abraham, George, Barack} por (1) segs, entonces decir (elemento (1) de {Lincoln, Washington, Obama} por (1) segs
2.2.3
AAP-2.O part b
listaEntradas ← [3, -1, 2, 10, -5]FOR EACH elemento IN listaEntradas{  IF(elemento > 0  AND  elemento * elemento > 4)  {    DISPLAY(elemento)  }}

¿Qué se mostrará como resultado de ejecutar el segmento de código dado?
9, 1, 4, 100, 25
9, 100
3, 2, 10
3, 10
2.2.3
PROCEDURE Misterio(listaNúmeros, númeroObjetivo){  contador ← 0  FOR EACH número IN listaNúmeros  {    IF(número > númeroObjetivo)    {      contador ← contador + 1    }  }  RETURN(contador)}misNotasMatemáticas ← [100, 80, 90, 80, 60, 100, 50, 100]Misterio(misNotasMatemáticas, 60)

¿Qué se devolverá si se ejecuta el código anterior?
[100, 80, 90, 80, 100, 100]
7
6
60
2.3.2
No hay un bloque ≤ incorporado en Snap!. Supongamos que quisiéramos construir uno. ¿Cuáles dos de las siguientes expresiones booleanas son equivalentes a la expresión núm menor o igual a predicado 23?
(num < 23) y (num = 23)
(núm < 23) o (núm = 23)
no (núm > 23)
no (núm > 22)
2.3.2
¿Cuál de las siguientes expresiones reportará verdadero?
  1. (T y F) y (no (T y F))
  2. (no (T o F)) o (T o F)
Solamente I
Solamente II
I y II
Ni I ni II

Laboratorio 4: Matemáticas con computadoras

+
2.4.1
AAP-2.L.2
Los algoritmos que tienen el mismo aspecto pueden tener resultados diferentes. El siguiente fragmento de código incompleto fue diseñado para probar si
número
es impar:
IF (MISSING CONDITION){  DISPLAY "Es impar".}

¿Cuál de los siguientes se puede usar en lugar de MISSING CONDITION?
número MOD 1 = 0
número MOD 1 = 1
número MOD 2 = 0
número MOD 2 = 1
2.4.1
¿Cuál es el valor de 11 módulo (2 + 3)?
1
0.2
2
2.2
2.4.3

¿Cuándo se mostrará 'Error. Entrada no válida'?

mayorOIgual
PROCEDURE mayorOIgual(a, b)    IF(a > b)    {        RETURN(verdadero)    }    ELSE    {        RETURN(a = b)    }    DISPLAY"Error. Entrada  no válida.")}
Cuando
a > b
es verdadero.
Cuando
a > b
es falso.
Siempre
Nunca
\ No newline at end of file diff --git a/cur/programming/2-complexity/unit-2-self-check.html b/cur/programming/2-complexity/unit-2-self-check.html new file mode 100644 index 0000000000..ace23b61b7 --- /dev/null +++ b/cur/programming/2-complexity/unit-2-self-check.html @@ -0,0 +1,19 @@ + + + + + + + + + + +Unit 2 Self-Check Questions + + + + +

Unit 2: Abstraction

+

Lab 1: Games

+
2.1.1
Examples like this one are useful to test your understanding of assignment to variables, but you wouldn't use a sequence of assignments like this in an actual program.
What value will this code display?
a ← 3b ← aa ← 4DISPLAY(b)
3
4
a
b
2.1.1
What value will this script report?
set m to 9, set k to 5, set m to (m + 1), set k to (k - m), report k
-5
3
-4
5
2.1.2
We really shouldn't be encouraging students to mutate a block's inputs. There are really two issues here; one is with the x=x+1 style of programming altogether, and the second is that formal parameters specifically shouldn't generally be mutated; it's better to make a script variable that's initialized to the input value. (If we change this, we need to update the Guided Notes.) --MF, 6/26/21 with BH
mystery function (input):if (input < 5) (repeat until (input = 5)(    say (input) for (1) secs,    set (input) to (input + 1))report (finished) Which inputs to mystery function will report "finished"?
Any integer
Only integers greater than or equal to 5
Only integers less than 5
Only 5
2.1.2
mystery function (input):if (input < 5) (repeat until (input = 5)(    say (input) for (1) secs,    set (input) to (input + 1))report (finished) What will the sprite say if you run the same function with the input 1?
speech bubble saying '4'
speech bubble saying '5'
four speech bubbles saying '1', '2', '3', and then '4'
five speech bubbles saying '1', '2', '3', '4', and then '5'
The feedback is not finished because I realized that BH might object to changing the value of an input variable... --MF, 3/1/19
2.1.2
mystery function (input):if (input < 5) (repeat until (input = 5)(    say (input) for (1) secs,    set (input) to (input + 1))report (finished) What will happen if you run the same function with the input 9?
The sprite will say 9, and the block will report "finished."
The sprite will say 9, 8, 7, 6, and the block will report "finished."
The sprite will say 9, 10, 11, 12, 13, … and keep counting, and the block will never report "finished."
The sprite will say nothing, and the block will report "finished."
The feedback is not finished because I realized that BH might object to changing the value of an input variable... --MF, 3/1/19
2.1.5

AAP-2.N part b
Which of the following blocks will report a list of length 3?

Choose all that apply.
list (pineapple strawberry kiwi)
item 3 of {pineapple, strawberry, kiwi}
item 2 of {lemon, {pineapple, strawberry, kiwi}}
list () (pineapple) ()
2.2.2

Imagine you make a variable capitals and use set to give this list of lists a name:
set (capitals) to {{Augusta, Maine}, {Boise, Idaho}, {Columbia, South Carolina}, {Des Moines, Iowa}}
Which of the following statements are true?

Choose all that apply.

item (1) of (capitals) reports a list with two items: "Augusta" and "Maine".
item (1) of (item (1) of (capitals)) reports the word "Augusta".
item (last) of (item (2) of (capitals)) reports the word "Iowa".
(length) of (capitals) reports the number 8.
all but first of (item (last) of (capitals)) reports a list with one item: "Iowa".
item (3) of (capitals) reports the string "Boise".
item (last) of (all but first of (capitals)) reports the string "Iowa".
(length) of (item (1) of (capitals)) reports the number 2.
2.2.3

Which of the scripts below will produce the following sprite behavior?
sprite saying Abraham then Lincoln
(When you run the script, though, it actually says Abraham Lincoln only once.)

Choose all that apply.

for each (item) of {Abraham, Lincoln} [say (item) for (1) secs]
say {Abraham, Lincoln} for (2) secs
say (item (1) of {Abraham Lincoln, George Washington, Barack Obama}) for (2) secs
say (item (1) of {Abraham, George, Barack} for (1) secs, then say (item (1) of {Lincoln, Washington, Obama} for (1) secs
2.2.3
AAP-2.O part b
inputList ← [3, -1, 2, 10, -5]FOR EACH item IN inputList{  IF(item > 0  AND  item * item > 4)  {    DISPLAY(item)  }}

What will be displayed as a result of running the code segment given?
9, 1, 4, 100, 25
9, 100
3, 2, 10
3, 10
2.2.3
PROCEDURE Mystery(numberList, targetNumber){  counter ← 0  FOR EACH number IN numberList  {    IF(number > targetNumber)    {      counter ← counter + 1    }  }  RETURN(counter)}myMathGrades ← [100, 80, 90, 80, 60, 100, 50, 100]Mystery(myMathGrades, 60)

What will be returned if the code above is run?
[100, 80, 90, 80, 100, 100]
7
6
60
2.3.2
There's no built in ≤ block in Snap!. Suppose we wanted to build one. Which two of the following Boolean expressions are equivalent to the expression num less than or equal to 23 predicate?
(num < 23) and (num = 23)
(num < 23) or (num = 23)
not (num > 23)
not (num > 22)
2.3.2
Which of the following expressions will report true?
  1. (T and F) and (not (T and F))
  2. (not (T or F)) or (T or F)
I only
II only
I and II
Neither I nor II

Lab 4: Making Computers Do Math

+
2.4.1
AAP-2.L.2
Algorithms that look the same may have different results. The following incomplete code fragment was designed to test if
number
is odd:
IF (MISSING CONDITION){  DISPLAY "It is odd."}

Which of the following can be used in place of the MISSING CONDITION?
number MOD 1 = 0
number MOD 1 = 1
number MOD 2 = 0
number MOD 2 = 1
2.4.1
What's the value of 11 mod (2 + 3)?
1
0.2
2
2.2
2.4.3

When will "Error. Invalid entry." be displayed?

PROCEDURE greaterThanOrEqualTo(a, b)    IF(a > b)    {        RETURN(true)    }    ELSE    {        RETURN(a = b)    }    DISPLAY("Error. Invalid entry.")}
When
a > b
is true.
When
a > b
is false.
Always
Never
\ No newline at end of file diff --git a/cur/programming/2-complexity/unit-2-vocab.es.html b/cur/programming/2-complexity/unit-2-vocab.es.html new file mode 100644 index 0000000000..fc8d12c8df --- /dev/null +++ b/cur/programming/2-complexity/unit-2-vocab.es.html @@ -0,0 +1,18 @@ + + + + + + + + + + +Unidad 2 Vocabulario + + + + +

Unidad 2: Abstracción

+

Laboratorio 1: Juegos

+
2.1.1: Variable
AAP-1.A.1

Una variable es como un cuadro que puede contener un valor a cada vez, como una palabra, un disfraz o una lista (que puede contener muchas cosas). Puedes mirar lo que hay dentro las veces que quieras.

En Unidad 1 Laboratorio 2 Página 2: Hacer que los programas hablen, aprendiste sobre abstracción de procedimientos: dar nombres a los programas colocándolos en nuevos bloques. Aquí, estamos comenzando a observar la abstracción de datos, dando nombres a números, texto, listas, etc. Cuando le das un nombre a algo, puedes referirte a él sin saber exactamente cuál es el valor.
2.1.1: Variable Local

Una variable local se puede configurar o usar solo en el entorno en el que se define. Este término incluye entradas a procedimientos y variables creadas por el bloque para o variables de programa.

2.1.2: Predicado y valor booleano
Leer más ¿Cuál es el origen de la palabra booleano?

La palabra booleano se origina en el nombre de una persona, George Boole, que inventó la rama de las matemáticas que se ocupa de las operaciones booleanas (como y, o, y no).

Un predicado es un reportero en forma de hexágono que hace una pregunta de verdadero/falso como estos ejemplos:
8 > 7 reporta verdadero 6 > 7 reporta falso

AAP-2.E.1

Los predicados reportan un valor booleano (ya sea verdadero o falso).

2.1.2

Los bloques si y si / sino se denominan condicionales porque controlan el código en función de una condición verdadera o falsa.

Haz clic para ver ejemplos de predicados que se usan dentro de condicionales.
más complicado quién {    si (número al azar entre (1) y (4)) = (3) {        reportar (unir (quién) (', quién') (hace) ( ) (quién) (,))    } sino {        reportar (quién)    }} cuando se pulse bandera verde:repetir hasta que (tocando (líder)?){    apuntar en dirección (líder)    mover (1) pasos}
2.1.4: Variable global

Una variable global es una variable que todos los scripts del programa pueden utilizar.

2.1.4

Establecer el valor inicial de una variable se conoce como inicializar la variable.

2.1.5: Índice

El número de posición se denomina índice del elemento en la lista.
elemento (2) de (lista (manzana) (cantalupo) (plátano)) con una burbuja de texto que dice 'cantalupo'
En esta lista, 1 es el índice del elemento "manzana", 2 es el índice del elemento "cantalupo", y así sucesivamente.

AAP-1.D.8

En Snap! y en el examen AP, el índice siempre es un número entero (1, 2, 3, 4, etc.). Es un error utilizar un índice inferior a 1 o superior a la longitud de la lista.

Laboratorio 2: Elaboración de listas

2.2.1
AAP-1.C.2

Un elemento es otro nombre para un artículo de una lista. (Si el mismo valor está en la lista dos veces, entonces contará como dos elementos diferentes). Cada elemento tiene un índice (posición) único en la lista.

2.2.2: Tipos de datos
2.2.2: Tipos de datos abstractos El constructor y el selector juntos implementan el elemento de prueba tipo de datos abstracto.
2.2.2: Tabla

Una tabla es una estructura de datos bidimensional con filas y columnas. Si conoces un programa de hojas de cálculo, lo que este muestra es una tabla.

En Snap!, una tabla se implementa como una lista de listas, en la que cada sublista es una fila de la tabla.

2.2.2: Sublista

Una sublista es una lista que se utiliza como elemento de otra lista.

(La palabra sublista también se usa para referirse a algún subconjunto de una lista).

2.2.3

Utilizar el resultado de elemento como entrada para dirección de contacto se denomina composición de funciones.

2.2.3: Recorrer una lista
AAP-2.O.2

Recorriendo una lista significa mirar cada elemento de la lista. Para cada es iterativo. Es decir, es repetitivo, como para, que también puede atravesar una lista. Pero a diferencia de para, para cada recorre la lista sin usar números de índice.

Laboratorio 3: Tomar decisiones

2.3.1: Dominio y rango
2.3.1: Secuenciación, selección e iteración
Selección: AAP-2.G.1; secuenciación, selección, iteración: AAP-2.A.4

Selección decide (selecciona) qué parte de un algoritmo ejecutar basado en si una condición es verdadera o falsa.

Cada algoritmo se puede construir usando secuenciación (siguiendo los pasos en orden), selección (decidir) e iteración (repetir).

2.3.3
AAP-2.I.1

Una sentencia condicional anidada es una sentencia si o si / sino dentro de otra sentencia si / sino.

2.3.5: Cadena e índice
2.3.6

Todas las palabras del acertijo están relacionadas con el curso de AP sobre los Principios de Ciencias de la computación.

Laboratorio 4: Matemáticas con computadoras

2.4.2: APIs
AAP-3.D.4, AAP-3.D.5

Una interfaz de programa de aplicación (API, por sus siglas en inglés) documenta lo que un programador necesita saber sobre el uso de la biblioteca: es una descripción del propósito, las entradas y las salidas de cada procedimiento (pero no sus algoritmos).

¿Qué es una API web?

Un tipo común de API es una API web en la que la biblioteca existe en la computadora de otra persona. Por ejemplo, la API de los Mapas de Google describe cómo incrustar un mapa de Google en tu propio sitio web.

I'm actually inclined to cut all the rest of this yellow box. --MF, 1/15/20

Una API web es solo una llamada a un procedimiento en otra máquina. Por ejemplo, estas son tres notaciones diferentes para la misma llamada de procedimiento, que busca el número de búsquedas de "BJC" en EE. UU.:

La única diferencia está en que la URL muestra dónde encontrar el procedimiento en Internet.
2.4.2
AAP-3.D.1

Una biblioteca de software es una colección de procedimientos que se pueden usar en programas.

Laboratorio 5: Derechos de autor

2.5.2
IOC-1.F.5
2.5.2
IOC-1.F.5

Se utilizan ideas similares a Creative Commons para diferentes tipos de material:

\ No newline at end of file diff --git a/cur/programming/2-complexity/unit-2-vocab.html b/cur/programming/2-complexity/unit-2-vocab.html new file mode 100644 index 0000000000..00e96b5d52 --- /dev/null +++ b/cur/programming/2-complexity/unit-2-vocab.html @@ -0,0 +1,18 @@ + + + + + + + + + + +Unit 2 Vocabulary + + + + +

Unit 2: Abstraction

+

Lab 1: Games

+
2.1.1: Variable
AAP-1.A.1

A variable is like a labeled box that can hold one value at a time, such as one word, one costume, or one list (which can contain many things). You can look at what's inside as many times as you want.

On Unit 1 Lab 2 Page 2: Making Programs Talk, you learned about procedural abstraction: giving scripts names by putting them in new blocks. Here, we are starting to look at data abstraction, giving names to numbers, text, lists, etc. When you give something a name, you can refer to it without knowing exactly what the value is.
2.1.1: Local Variable

A local variable can be set or used only in the environment in which it is defined. This term includes inputs to procedures and variables created by the for or script variables block.

2.1.2: Predicate and Boolean value
Read More Why is Boolean capitalized?

The word Boolean is capitalized because it's named after a person, George Boole, who invented the branch of mathematics dealing with Boolean operations (such as and, or, and not).

A predicate is a hexagon-shaped reporter that asks a true/false question such as these examples:
8 > 7 reporting true 6 > 7 reporting false

AAP-2.E.1

Predicates report a Boolean value (either true or false).

2.1.2

The if and if-else blocks are called conditionals because they control the code based on a true-or-false condition.

Click for examples of predicates being used inside conditionals.
more complicated who {    if (pick random (1) to (4)) = (3) {        report (join (who) (', who') (does what) ( ) (who) (,))    } else {        report (who)    }} when green flag clicked:repeat until (touching (Leader)?){    point towards (Leader)    move (1) steps}
2.1.4: Global Variable

A global variable is a variable that is usable by all scripts in the program.

2.1.4

Setting the starting value of a variable is known as initializing the variable.

2.1.5: Index

The position number is called the index of the item in the list.
item (2) of (list (apple) (cantaloupe) (banana)) reporting 'cantaloupe'
In this list, 1 is the index of the item "apple," 2 is the index of the item "cantaloupe," and so on.

AAP-1.D.8

In Snap! and on the AP exam, the index is always a whole number (1, 2, 3, 4, etc.). It is an error to use an index less than 1 or greater than the length of the list.

Lab 2: Making Lists

2.2.1
AAP-1.C.2

An element is another name for an item in a list. (If the same value is in the list twice, that counts as two different elements.) Each element has a unique index (position) in the list.

2.2.2: Data Types
2.2.2: Abstract Data Types The constructor and selector together implement the quiz item abstract data type.
2.2.2: Table

A table is a two-dimensional data structure with rows and columns. If you've used a spreadsheet program, what it displays is a table.

In Snap!, a table is implemented as a list of lists, in which each sublist is one row of the table.

2.2.2: Sublist

A sublist is a list used as an item of another list.

(The word sublist is also used to refer to some subset of a list.)

2.2.3

Using the result from item as the input to address from contact is called composition of functions.

2.2.3: Traversing a List
AAP-2.O.2

Traversing a list means looking at each item of the list. For each is iterative. That is, it's repetitive, like for, which can also traverse a list. But unlike for, for each traverses the list without using index numbers.

Lab 3: Making Decisions

2.3.1: Domain and Range
2.3.1: Sequencing, Selection, Iteration
Selection: AAP-2.G.1; sequencing, selection, iteration: AAP-2.A.4

Selection means deciding (selecting) which part of an algorithm to run based on whether a condition is true or false.

Every algorithm can be constructed using sequencing (following steps in order), selection (deciding), and iteration (repeating).

2.3.3
AAP-2.I.1

A nested conditional statement is an if or if else statement inside another if else statement.

2.3.5: String and Index
2.3.6

All the words in the puzzle are related to the AP CS Principles course.

Lab 4: Making Computers Do Math

2.4.2: APIs
AAP-3.D.4, AAP-3.D.5

An application program interface (API) documents what a programmer needs to know about using a library: it's a description of each procedure's purpose, inputs, and outputs (but not its algorithms).

What is a Web API?

A common kind of API is a web API in which the library exists on someone else's computer. For example, the Google Maps API describes how to embed a Google Map on your own website.

I'm actually inclined to cut all the rest of this yellow box. --MF, 1/15/20

A web API is just a call to a procedure on another machine. For example, these are three different notations for the same procedure call, which looks up the number of searches for "BJC" in the US:

The only difference is that the URL shows where on the Internet to find the procedure.
2.4.2
AAP-3.D.1

A software library is a collection of procedures that can be used in programs.

Lab 5: Copyrights

2.5.2
IOC-1.F.5
2.5.2
IOC-1.F.5

Ideas similar to Creative Commons are used for particular kinds of material:

\ No newline at end of file diff --git a/cur/programming/3-lists/unit-3-exam-reference.es.html b/cur/programming/3-lists/unit-3-exam-reference.es.html new file mode 100644 index 0000000000..9ae8548cb1 --- /dev/null +++ b/cur/programming/3-lists/unit-3-exam-reference.es.html @@ -0,0 +1,18 @@ + + + + + + + + + + +Unidad 3 Examen AP + + + + +

Unidad 3: Estructuras de datos

+

Laboratorio 1: Lidiar con la complejidad

+
3.1.1

Hay problemas con un robot en una cuadrícula con procedimientos especiales que no existen en Snap!:

Puedes leer más sobre estos procedimientos de lenguaje AP en la Hoja de referencia de Snap! en la sección Robot en la parte inferior.
\ No newline at end of file diff --git a/cur/programming/3-lists/unit-3-exam-reference.html b/cur/programming/3-lists/unit-3-exam-reference.html new file mode 100644 index 0000000000..4c4480a0e7 --- /dev/null +++ b/cur/programming/3-lists/unit-3-exam-reference.html @@ -0,0 +1,18 @@ + + + + + + + + + + +Unit 3 Exam Questions + + + + +

Unit 3: Data Structures

+

Lab 1: Dealing with Complexity

+
3.1.1

There are problems about a robot in a grid with special procedures that don't exist in Snap!:

You can read more about these AP language procedures on the Snap! Cheat Sheet in the Robot section at the bottom.
\ No newline at end of file diff --git a/cur/programming/3-lists/unit-3-self-check.es.html b/cur/programming/3-lists/unit-3-self-check.es.html new file mode 100644 index 0000000000..97f1302045 --- /dev/null +++ b/cur/programming/3-lists/unit-3-self-check.es.html @@ -0,0 +1,18 @@ + + + + + + + + + + +Unidad 3 Preguntas de Autocomprobacion + + + + +

Unidad 3: Estructuras de datos

+

Laboratorio 2: Lista de contactos

+
3.2.5
¿Cuáles de las siguientes afirmaciones son verdaderas acerca de esta lista?
asignar a (números y palabras) el valor {conejo, 5, beneficio, es, 34, papalote, 2, 305, el, 61}
mapear (letra (1) de ()) sobre (números y palabras) reporta la lista {r, 5, b, i, 3, k, 2, 3, t, 6}.
mapear (elemento (1) de ()) sobre (palabras y números) reporta la lista {conejo}.
Las dos anteriores.
Ninguna de las anteriores.
3.2.5
¿Cuáles de las siguientes afirmaciones son verdaderas acerca de esta lista?
asignar a (capitales) el valor {{Augusta, Maine}, {Boise, Idaho}, {Columbia, Carolina del Sur}, {Des Moines, Iowa}}
Elige todos los que correspondan.
¿Por qué no usar un tipo de datos abstractos?

La lista dentro de una lista que se muestra arriba deja más claro ahora que responde a este elemento de autocomprobación cuál es la estructura, pero tienes razón, en un programa real sería mejor usar un tipo de dato abstracto:
estado: (Augusta) capital: (Maine)

mapear (elemento (1) de ()) sobre (capitales) reporta la lista {Augusta, Boise, Columbia, Des Moines}.
mapear (elemento (1) de ()) sobre (capitales) reporta la lista {Augusta, Maine}.
mapear (letra (1) de ()) sobre (capitales) reporta la lista {A, B, C, D}.
mapear (todos menos el primero de ()) sobre (capitales) reporta la lista {Maine, Idaho, Carolina del Sur, Iowa}.
mapear (todos menos el primero de ()) sobre (capitales) reporta la lista {{Boise, Idaho}, {Columbia, Carolina del Sur}, {Des Moines, Iowa}}.
3.2.5

Considera esta lista de cuadrados:
asignar a (cuadrados) el valor {1, 4, 9, 16, 25, 36, 49, 64, 81, 100, 121, 144, 169, 196, 225}
¿Cuál de las siguientes expresiones reportará una lista? Elige todas las que correspondan.

mapear (raíz cuadrada de ()) sobre (cuadrados)
mantener los elementos donde (() módulo (2) = 0) de (cuadrados)
combinar los elementos de (cuadrados) con (unir)
mantener elementos donde (letra (longitud de ()) de () = 1) de (cuadrados)
combinar los elementos de (cuadrados) con (+)
mapear ((0)-()) sobre (cuadrados)
\ No newline at end of file diff --git a/cur/programming/3-lists/unit-3-self-check.html b/cur/programming/3-lists/unit-3-self-check.html new file mode 100644 index 0000000000..e989bfa119 --- /dev/null +++ b/cur/programming/3-lists/unit-3-self-check.html @@ -0,0 +1,18 @@ + + + + + + + + + + +Unit 3 Self-Check Questions + + + + +

Unit 3: Data Structures

+

Lab 2: Contact List

+
3.2.5
Which of the following statements are true about this list?
set (words and numbers) to {rabbit, 5, benefit, is, 34, kite, 2, 305, the, 61}
map (letter (1) of ()) over (words and numbers) reports the list {r, 5, b, i, 3, k, 2, 3, t, 6}.
map (item (1) of ()) over (words and numbers) reports the list {rabbit}.
Both of the above.
None of the above.
3.2.5
Which of the following statements are true about this list?
set (capitals) to {{Augusta, Maine}, {Boise, Idaho}, {Columbia, South Carolina}, {Des Moines, Iowa}}
Choose all that apply.
Why not use an ADT?

The list inside a list shown above makes it clearest to you now as you answer this self-check item what the structure is, but you're right, in an actual program it would be better to use an abstract data type:
state: (Augusta) capital: (Maine)

map (item (1) of ()) over (capitals) reports the list {Augusta, Boise, Columbia, Des Moines}.
map (item (1) of ()) over (capitals) reports the list {Augusta, Maine}.
map (letter (1) of ()) over (capitals) reports the list {A, B, C, D}.
map (all but first of ()) over (capitals) reports the list {Maine, Idaho, South Carolina, Iowa}.
map (all but first of ()) over (capitals) reports the list {{Boise, Idaho}, {Columbia, South Carolina}, {Des Moines, Iowa}}.
3.2.5

Consider this list of squares:
set (squares) to {1, 4, 9, 16, 25, 36, 49, 64, 81, 100, 121, 144, 169, 196, 225}
Which of the following expressions will report a list? Choose all that apply.

map (sqrt of()) over (squares)
keep items (()mod(2)=0) from (squares)
combine (squares) using (()+())
keep items (letter (length of ()) of () = 1) from (squares)
combine (squares) using (join ()()) items of
map ((0)-()) over (squares)
\ No newline at end of file diff --git a/cur/programming/3-lists/unit-3-vocab.es.html b/cur/programming/3-lists/unit-3-vocab.es.html new file mode 100644 index 0000000000..1a30254444 --- /dev/null +++ b/cur/programming/3-lists/unit-3-vocab.es.html @@ -0,0 +1,18 @@ + + + + + + + + + + +Unidad 3 Vocabulario + + + + +

Unidad 3: Estructuras de datos

+

Laboratorio 1: Lidiar con la complejidad

+
3.1.3

Llamar a un procedimiento desde dentro de sí mismo se llama recursión.

3.1.4: Abstracción
AAP-3.B.1, AAP-3.B.5

Como aprendiste en la Unidad 1, Laboratorio 2, Página 2: Hacer que los programas hablen, abstracción procesal es el proceso de desarrollar un programa dividiendo un gran problema en subproblemas más pequeños.

Crear un bloque dibujar ladrillo te permite pensar en términos de un procedimiento con un nombre relacionado con el problema que estás resolviendo. Esto hace que tu código sea más fácil de leer; una vez que hayas codificado y depurado el bloque, no necesitas pensar en cómo funciona cada vez que lo usas. Esa es la belleza de la abstracción procedimental.

3.1.4
AAP-3.B.2, AAP-3.B.3

Modularidad es el proceso de romper un problema en pedazos más pequeños. La modularidad es una forma de abstracción procedimental.

3.1.5

Un clon es una copia de un objeto que comparte información con su objeto padre (el objeto original). Por ejemplo, los clones tienen copias de cualquier secuencia de comandos del padre, y si se cambia la secuencia de comandos del padre, entonces las secuencias de comandos de los clones también cambian. Sin embargo, los cambios que realiza en un clon no se comparten con el padre, por lo que puede hacer cosas como mover cada clon a una posición diferente.

3.1.6

La depuración es el arte de identificar errores en los programas informáticos y corregirlos.

Laboratorio 2: Lista de contactos

3.2.2: entrada y salida
CRD-2.C.1, CRD-2.C.4, CRD-2.C.6, CRD-2.D.1, CRD-2.D.2

Usamos "entrada" vagamente para referirnos a las casillas vacías en un bloque que se llenan con valores. Pero entrada también se refiere a la información que ingresa el usuario en un programa, como en el bloque preguntar y esperar. La entrada del programa también puede provenir de tablas de datos, sonidos, imágenes, videos u otros programas.

Del mismo modo, salida del programa significa cualquier dato enviado desde su programa al usuario o a cualquier dispositivo. Por lo general, la salida depende de la entrada.

3.2.4
AAP-3.B.2, AAP-3.B.3

Modularidad es el proceso de dividir un proyecto de programación en subproblemas separados. Por ejemplo, en la página 2 de este laboratorio, creaste un código para agregar un contacto a tu aplicación y, en esta página, creaste un código para encontrar contactos.

3.2.5

Una función de orden superior es una función que toma una función como entrada (o reporta una función como salida).

Laboratorio 3: Tres en línea

3.3.1: Variable del objeto

Una variable del objeto es como una variable global en el sentido de que no pertenece a un programa en particular, pero sí pertenece a un objeto en particular.

Laboratorio 4: Robots e inteligencia artificial

3.4.1

La inteligencia artificial (IA) es un campo de la informática que se define vagamente como "intentar que las computadoras piensen".

\ No newline at end of file diff --git a/cur/programming/3-lists/unit-3-vocab.html b/cur/programming/3-lists/unit-3-vocab.html new file mode 100644 index 0000000000..1fea101b68 --- /dev/null +++ b/cur/programming/3-lists/unit-3-vocab.html @@ -0,0 +1,18 @@ + + + + + + + + + + +Unit 3 Vocabulary + + + + +

Unit 3: Data Structures

+

Lab 1: Dealing with Complexity

+
3.1.3

Calling a procedure from inside itself is called recursion.

3.1.4: Abstraction
AAP-3.B.1, AAP-3.B.5

As you learned in Unit 1 Lab 2 Page 2: Making Programs Talk, procedural abstraction is the process of developing a program by breaking up a large problem into smaller sub-problems.

Creating a draw brick block lets you think in terms of a procedure with a name related to the problem you are solving. This makes your code easier to read, and once you've coded and debugged the block, you don't need to think about how it works each time you use it. That's the beauty of procedural abstraction.

3.1.4
AAP-3.B.2, AAP-3.B.3

Modularity is the process of breaking a problem into smaller pieces. Modularity is a form of procedural abstraction.

3.1.5

A clone is a copy of a sprite that shares information with its parent sprite (the original sprite). For example, clones have copies of any scripts from the parent, and if the parent's script is changed, then the clones' scripts change too. However, changes you make to a clone are not shared with the parent, so you can do things like move each clone to a different position.

3.1.6

Debugging is the art of identifying errors in computer programs and fixing them.

Lab 2: Contact List

3.2.1

An abstract data type (ADT) is a custom data type that's meaningful to your program. You learned about data types and ADTs on Unit 2 Lab 2 Page 2: Planning a Quiz App.

3.2.2: Input and Output
CRD-2.C.1, CRD-2.C.4, CRD-2.C.6, CRD-2.D.1, CRD-2.D.2

We use "input" loosely to mean the empty boxes in a block that get filled with values. But input also means information entered into a program by the user, as in the ask and wait block. Program input can also come from data tables, sounds, pictures, video, or other programs.

Similarly, program output means any data sent from your program to the user or to any device. Typically, the output depends on the input.

3.2.4
AAP-3.B.2, AAP-3.B.3

Modularity is the process of breaking a programming project up into separate sub-problems. For example on page 2 of this lab, you built code to add a contact to your app, and on this page, you built code to find contacts.

3.2.5

A higher-order function is a function that takes a function as input (or reports a function as output).

Lab 3: Tic-Tac-Toe

3.3.1: Sprite Variable

A sprite variable is like a global variable in that it doesn't belong to a particular script, but it does belong to a particular sprite.

Lab 4: Robots and Artificial Intelligence

3.4.1

Artificial intelligence (AI) is a field of computer science loosely defined as "trying to get computers to think."

\ No newline at end of file diff --git a/cur/programming/4-internet/unit-4-self-check.es.html b/cur/programming/4-internet/unit-4-self-check.es.html new file mode 100644 index 0000000000..a0a9403c68 --- /dev/null +++ b/cur/programming/4-internet/unit-4-self-check.es.html @@ -0,0 +1,20 @@ + + + + + + + + + + +Unidad 4 Preguntas de Autocomprobacion + + + + +

Unidad 4: ¿Cómo funciona Internet?

+

Laboratorio 1: Redes informáticas

+
4.1.1
¿Cuál de las siguientes no es una ventaja de almacenar datos usando la computación en la nube??
Previene la pérdida de datos debido al mal funcionamiento de la computadora personal del usuario.
Fácil de escalar desde el uso individual hasta la implementación por parte de grandes empresas.
Tiene potencial para ser amigable con el medio ambiente debido a que muchos usuarios comparten eficientemente grandes sistemas y recursos.
Seguridad y privacidad mejoradas con respecto al almacenamiento de datos en una computadora personal.
4.1.2
Gráfico de una red con un emisor y un receptor en cada extremo, y múltiples conexiones entre varios nodos entre ellos En este modelo de red, ¿cuál es el número mínimo de nodos (puntos de conexión) que pueden dejar de funcionar antes de que el emisor y el receptor no puedan comunicarse? (Aparte del remitente o el receptor, por supuesto).
1
2
3
4
5
4.1.2
Gráfico de una red con un emisor y un receptor en cada extremo, y múltiples conexiones entre varios nodos entre ellos En el mismo modelo de red, ¿cuál es el número máximo de nodos que pueden fallar y aun así permitir que el remitente y el receptor se comuniquen?
10
9
8
7
6

Laboratorio 2: Ciberseguridad

+
4.2.5
¿Cuáles de las siguientes son vulnerabilidades existentes de Internet, según los expertos?
Un ataque físico que consiste en cortar cables de fibra óptica.
Atacar los sistemas eléctricos que controlan la red de energía.
Erosionar la confianza que el público en general tiene en tu privacidad en línea y transacciones seguras en línea.

Laboratorio 4: Representación y compresión de datos

+
4.4.1
¿Cuál de los siguientes NO se puede expresar usando un bit?
El estado de un interruptor ON/OFF
El valor de una variable booleana
El resto al dividir un entero positivo por 2
La posición de la manecilla de la hora de un reloj
4.4.2
Una empresa minorista en línea en particular utiliza secuencias binarias de 9 bits para identificar cada producto único para la venta. Con la esperanza de aumentar el número de productos que vende, la compañía planea cambiar a secuencias binarias de 10 bits. ¿Cuál de las siguientes afirmaciones describe mejor la consecuencia de usar secuencias de 10 bits en lugar de secuencias de 9 bits?
Dos productos más se pueden identificar de forma única.
Diez productos más se pueden identificar de forma única.
El doble de productos se pueden identificar de forma única.
Diez veces más productos se pueden identificar de forma única.
4.4.5
Un programa en particular utiliza 4 bits para representar números enteros. Cuando ese programa suma los números 9 y 7, el resultado se da como 0. Identifica la mejor explicación del resultado.
Los datos se corrompieron durante la operación debido a una falla técnica.
El resultado se debió a un error de redondeo
El resultado se debió a un error de desbordamiento.
Se utilizó una representación de punto flotante para aproximar el resultado.
4.4.6
Un estudiante de cine graba una película en su teléfono inteligente y luego guarda una copia en su computadora. Se da cuenta de que la copia guardada es de una calidad de imagen mucho menor que la original. ¿Cuál de los siguientes podría NO ser una posible explicación para la menor calidad de imagen?
La película se guardó usando menos bits por segundo (una velocidad de bits más baja) que la película original.
La copia del archivo de película se corrompió de alguna manera en el proceso de guardado.
La película se guardó utilizando una técnica de compresión con pérdida.
Cada vez que se guarda un archivo de una computadora a otra, siempre se pierde cierta información.
4.4.6
Un artista visual está procesando una imagen digital. ¿Cuál de las siguientes opciones describe una transformación sin perdida de la que se puede recuperar la imagen original? Elige dos respuestas.
Crear el negativo de una imagen, donde los colores se invierten (las áreas oscuras aparecen claras).
Desenfocar los bordes de una imagen.
Crear una copia en escala de grises de una imagen.
Creación de una copia de la imagen volteada verticalmente.
4.4.6
¿Para cuál de los siguientes tipos datos podría usarse la compresión de datos con pérdida? Marca todas las respuestas que apliquen.
El código HTML de esta página web.
Imagen del escritorio del equipo.
Una película de acción en vivo en Netflix.
Una caricatura en Netflix.
Un libro digital, para ser leído en una computadora.
\ No newline at end of file diff --git a/cur/programming/4-internet/unit-4-self-check.html b/cur/programming/4-internet/unit-4-self-check.html new file mode 100644 index 0000000000..e51678ea3f --- /dev/null +++ b/cur/programming/4-internet/unit-4-self-check.html @@ -0,0 +1,20 @@ + + + + + + + + + + +Unit 4 Self-Check Questions + + + + +

Unit 4: How the Internet Works

+

Lab 1: Computer Networks

+
4.1.1
Which of the following is not an advantage of storing data using cloud computing?
Prevents loss of data due malfunction of user’s personal computer.
Easy to scale up from individual use to implementation by large companies.
Has potential to be environmentally friendly due to many users efficiently sharing large systems and resources.
Improved security and privacy over storing data on a personal computer.
4.1.2
graph of a network with a sender and a receiver at each end and multiple connections among multiple notes between them In this model of a network, what is the minimum number of nodes (connection points) that can stop working before the sender and the receiver can't communicate? (Other than the sender or the receiver themselves, of course.)
1
2
3
4
5
4.1.2
graph of a network with a sender and a receiver at each end and multiple connections among multiple notes between them In the same model network, what is the maximum number of nodes that can fail and still let Sender and Receiver communicate?
10
9
8
7
6

Lab 2: Cybersecurity

+
4.2.5
Which of the following are existing vulnerabilities of the Internet, according to experts?
A physical attack that involves cutting fiber-optic cables.
Attacking electrical systems that control the energy grid.
Eroding the trust and confidence that the general public has in their online privacy and secure online transactions.

Lab 4: Data Representation and Compression

+
4.4.1
Which of the following CANNOT be expressed using one bit?
The state of an ON/OFF switch
The value of a Boolean variable
The remainder when dividing a positive integer by 2
The position of the hour hand of a clock
4.4.2
A particular online retail company uses 9-bit binary sequences to identify each unique product for sale. Expecting to increase the number of products it sells, the company is planning to switch to 10-bit binary sequences. Which of the statements below best describes the consequence of using 10-bit sequences instead of 9-bit sequences?
Two more products can be identified uniquely.
Ten more products can be identified uniquely.
Twice as many products can be identified uniquely.
Ten times as many products can be identified uniquely.
4.4.5
A particular program uses 4 bits to represent whole numbers. When that program adds the numbers 9 and 7, the result is given as 0. Identify the best explanation of the result.
Data was corrupted during the operation due to a technical glitch.
The result was due to a round-off error.
The result was due to an overflow error.
A floating-point representation was used to approximate the result.
4.4.6
A film student records a movie on his smartphone and then saves a copy on his computer. He notices that the saved copy is of much lower image quality than the original. Which of the following could NOT be a possible explanation for the lower image quality?
The movie was saved using fewer bits per second (a lower bit rate) than the original movie.
The copy of the movie file was somehow corrupted in the process of saving.
The movie was saved using a lossy compression technique.
Whenever a file is saved from one computer to another, some information is always lost.
4.4.6
A visual artist is processing a digital image. Which of the following describe a lossless transformation from which the original image can be recovered? Choose two answers.
Creating the negative of an image, where colors are reversed (dark areas appear light).
Blurring the edges of an image.
Creating a grayscale copy of an image.
Creating a vertically flipped copy of the image.
4.4.6
For which of the following kinds of data would lossy compression be okay? Check as many as apply.
The HTML code for this web page.
Your computer's desktop picture.
A live-action movie on Netflix.
A cartoon on Netflix.
A digital book, to be read on a computer.
\ No newline at end of file diff --git a/cur/programming/4-internet/unit-4-vocab.es.html b/cur/programming/4-internet/unit-4-vocab.es.html new file mode 100644 index 0000000000..490f042dbd --- /dev/null +++ b/cur/programming/4-internet/unit-4-vocab.es.html @@ -0,0 +1,18 @@ + + + + + + + + + + +Unidad 4 Vocabulario + + + + +

Unidad 4: ¿Cómo funciona Internet?

+

Laboratorio 1: Redes informáticas

+
4.1.1
4.1.1
4.1.1
4.1.2
CSN-1.A.5, CSN-1.A.6, CSN-1.B.6, CSN-1.E.2, CSN-1.E.5
4.1.3

TCP/IP son un par de protocolos que proporcionan dos niveles de abstracción:

4.1.3
CSN-1.B.3, CSN-1.C.1

Laboratorio 2: Ciberseguridad

4.2.1: Cifrado y descifrado
IOC-2.B.5
4.2.1: Cifrado Simétrico
IOC-2.B.5

Los cifrados de sustitución son ejemplos de cifrado simétrico porque utilizan la misma clave tanto para el cifrado como para el descifrado.

4.2.3
IOC-2.B.5

El cifrado de clave pública utiliza un par de claves: una clave pública para el cifrado y una clave privada para el descifrado. El remitente usa la clave pública para cifrar el mensaje y el receptor usa su clave privada para descifrarlo.

4.2.3

SSL/TLS (capa de conexión segura/seguridad de la capa de transporte) es el estándar utilizado para la transferencia de información criptográficamente segura en Internet.

4.2.3
IOC-2.B.6

Las autoridades de certificación son organizaciones que emiten certificados digitales para verificar quién es el propietario de las claves de cifrado utilizadas para las comunicaciones seguras.

En lugar de confiar en que el sitio web es quien dice ser, ahora debes confiar en que la Autoridad de certificación sea confiable.

4.2.5:

Un punto de acceso no autorizado es un punto de acceso inalámbrico que da acceso a una red segura sin la autorización del administrador de la red.

4.2.5
malware: IOC-2.B.9, keylogging: IOC-2.C.2, virus: IOC-2.B.8, software antivirus o antimalware: IOC-2.B.7, phishing: IOC-2 .C .1
4.2.5

Un ataque DDoS (Denegación de Servicio Distribuida) usa un virus para inundar un servidor con muchas solicitudes de muchas computadoras a la vez para que a los usuarios de ese servidor se les niegue el servicio.

Laboratorio 3: Comunidad e interacciones en línea

4.3.5
IOC-1.C.1, IOC-1.C.2, IOC-1.C.3

La brecha digital se refiere al acceso desigual a las computadoras e Internet basado en la pobreza, el racismo, el sexismo, el aislamiento en el campo, la edad y otros factores. La brecha digital afecta tanto a las personas dentro de un país como a los propios países.

4.3.6
4.3.6
CRD-1.A.1, CRD-1.A.2

Laboratorio 4: Representación y compresión de datos

4.4.1: byte y palabra
DAT-1.A.4

Un byte tiene ocho bits.

una palabra es una secuencia de cuántos bits procesa la CPU a la vez. A partir de 2017, las palabras son de 32 o 64 bits.

4.4.1: Bit
DAT-1.A.3

Un bit es una sola unidad de datos que solo puede tener uno de dos valores. Normalmente representamos los dos valores como 0 (apagado) y 1 (encendido).

4.4.2

Los datos analógicos tienen valores que cambian sin problemas, a diferencia de los datos digitales que cambian en intervalos discretos.

Muestreo significa medir valores, llamados muestras, de una señal analógica a intervalos regulares.

La frecuencia de muestreo es el número de muestras medidas por segundo.

4.4.2

Una secuencia binaria (también se denomina bitstream) es una cadena de unos y ceros.

4.4.3

Ancho: el número de bits que procesa una CPU a la vez

Palabra: una secuencia binaria con esa cantidad de bits

4.4.4

La notación científica (como 2.350.000 = 2,35 × 106) utiliza potencias de diez para representar valores muy grandes o muy pequeños. El punto flotante (o coma flotante) es la misma idea pero con potencias de dos.

4.4.5: Bit
DAT-1.A.3

La palabra "bit" es una abreviatura de la expresión en inglés binary digit (dígito binario).

4.4.6: Compresión sin pérdida

Los algoritmos de compresión de datos sin pérdida  (como PNG) son reversibles (no hay pérdida de calidad); puedes reconstruir los datos originales.

4.4.6: Compresión con pérdida

Los algoritmos de compresión de datos con pérdida no son totalmente reversibles; solo pueden reconstruir una aproximación de los datos originales.

\ No newline at end of file diff --git a/cur/programming/4-internet/unit-4-vocab.html b/cur/programming/4-internet/unit-4-vocab.html new file mode 100644 index 0000000000..590a78c7b2 --- /dev/null +++ b/cur/programming/4-internet/unit-4-vocab.html @@ -0,0 +1,18 @@ + + + + + + + + + + +Unit 4 Vocabulary + + + + +

Unit 4: How the Internet Works

+

Lab 1: Computer Networks

+
4.1.1
4.1.1
4.1.1
4.1.2
CSN-1.A.5, CSN-1.A.6, CSN-1.B.6, CSN-1.E.2, CSN-1.E.5
4.1.3

TCP/IP is a pair of protocols that provide two levels of abstraction:

4.1.3
CSN-1.B.3, CSN-1.C.1

Lab 2: Cybersecurity

4.2.1: Encryption and Decryption
IOC-2.B.5
4.2.1: Symmetric Encryption
IOC-2.B.5

Substitution ciphers are examples of symmetric encryption because they use the same key for both encryption and decryption.

4.2.3
IOC-2.B.5

Public key encryption uses a pair of keys: a public key for encryption and a private key for decryption. The sender uses the public key to encrypt the message, and receiver uses their private key to decrypt it.

4.2.3

SSL/TLS (secure sockets layer/transport layer security) is the standard used for cryptographically secured information transfer on the Internet.

4.2.3
IOC-2.B.6

Certificate authorities are organizations that issue digital certificates to verify who owns the encryption keys used for secured communications.

Instead of trusting that the website is who they say they are, you now have to trust that the Certificate Authority is reliable.

4.2.5:

A rogue access point is a wireless access point that gives access to a secure network without the authorization of the network administrator.

4.2.5
malware: IOC-2.B.9, keylogging: IOC-2.C.2, virus: IOC-2.B.8, antivirus or anti-malware software: IOC-2.B.7, phishing: IOC-2.C.1
4.2.5

A DDoS (Distributed Denial of Service) attack uses a virus to flood a server with many requests from many computers at once so that users of that server are denied service.

Lab 3: Community and Online Interactions

4.3.5
IOC-1.C.1, IOC-1.C.2, IOC-1.C.3

The digital divide refers to unequal access to computers and the Internet based on poverty, racism, sexism, isolation in the countryside, age, and other factors. The digital divide affects both individuals within a country and countries themselves.

4.3.6
4.3.6
CRD-1.A.1, CRD-1.A.2

Lab 4: Data Representation and Compression

4.4.1: Byte and Word
DAT-1.A.4

A byte is eight bits.

A word is a sequence of however many bits the CPU processes at a time. As of 2017, words are 32 or 64 bits.

4.4.1: Bit
DAT-1.A.3

A bit is a single unit of data that can only have one of two values. We usually represent the two values as 0 (off) and 1 (on).

4.4.2

Analog data have values that change smoothly, unlike digital data which change in discrete intervals.

Sampling means measuring values, called samples, of an analog signal at regular intervals.

The sampling rate is the number of samples measured per second.

4.4.2

A binary sequence (also called a bitstream) is a string of ones and zeros.

4.4.3

width: the number of bits that a CPU processes at a time

word: a binary sequence of that many bits

4.4.4

Scientific notation (such as 2,350,000 = 2.35 × 106) uses powers of ten to represent very large or very small values. Floating point is the same idea but with powers of two.

4.4.5: Bit
DAT-1.A.3

The word "bit" is an abbreviation for binary digit.

4.4.6: Lossless Compression

Lossless data compression algorithms (such as PNG) are reversible (there is no loss in quality); you can reconstruct the original data.

4.4.6: Lossy Compression

Lossy data compression algorithms are not fully reversible; you can reconstruct only an approximation of the original data.

\ No newline at end of file diff --git a/cur/programming/5-algorithms/unit-5-exam-reference.es.html b/cur/programming/5-algorithms/unit-5-exam-reference.es.html new file mode 100644 index 0000000000..04e196d1d7 --- /dev/null +++ b/cur/programming/5-algorithms/unit-5-exam-reference.es.html @@ -0,0 +1,20 @@ + + + + + + + + + + + + +Unidad 5 Examen AP + + + + +

Unidad 5: Algoritmos y Simulaciones

+

Laboratorio 1: Algoritmos de búsqueda y eficiencia

+
5.1.5
\ No newline at end of file diff --git a/cur/programming/5-algorithms/unit-5-exam-reference.html b/cur/programming/5-algorithms/unit-5-exam-reference.html new file mode 100644 index 0000000000..b202895731 --- /dev/null +++ b/cur/programming/5-algorithms/unit-5-exam-reference.html @@ -0,0 +1,18 @@ + + + + + + + + + + +Unit 5 Exam Questions + + + + +

Unit 5: Algorithms and Simulations

+

Lab 1: Search Algorithms and Efficiency

+
5.1.5
\ No newline at end of file diff --git a/cur/programming/5-algorithms/unit-5-self-check.es.html b/cur/programming/5-algorithms/unit-5-self-check.es.html new file mode 100644 index 0000000000..ec16bbe66b --- /dev/null +++ b/cur/programming/5-algorithms/unit-5-self-check.es.html @@ -0,0 +1,21 @@ + + + + + + + + + + + + +Unidad 5 Preguntas de Autocomprobacion + + + + +

Unidad 5: Algoritmos y Simulaciones

+

Laboratorio 1: Algoritmos de búsqueda y eficiencia

+
5.1.3
AAP-2.P part b, AAP-2.P.2
Para utilizar una búsqueda binaria, los datos deben ser...
binarios
ordenados
desordenados
lineales
5.1.3
¿Cuál de las siguientes preguntas se puede responder con una búsqueda binaria, suponiendo que los datos estén ordenados? Marca todas las que apliquen:
¿Cuál es el número de teléfono de mi amigo Rasheed?
Dame una lista de todas las canciones de Beyoncé.
Dime si el pan está en la lista de compras.
¿Quién de mi lista de contactos vive en la Gran Avenida?
5.1.5
La siguiente tabla muestra el tiempo que tarda la computadora en realizar varias tareas sobre los datos de ciudades de diferentes tamaños.

Tarea Ciudad pequeña
(población 1,000)
Ciudad mediana
(población 10,000)
Ciudad grande
(población 100,000)
Entrada de datos 2 horas 20 horas 200 horas
Copia de seguridad de los datos 0.5 hora 5 horas 50 horas
Búsqueda a través de los datos 5 horas 15 horas 25 horas
Clasificación de datos 0.01 hora 1 hora 100 hora

Basado en la información de la tabla, cuál de las siguientes tareas es probable que tome la mayor cantidad de tiempo cuando se amplía para una ciudad con una población de 1,000,000.
Entrar datos
Realizar una copia de seguridad de los datos
Buscar entre los datos
Clasificar datos
5.1.6
¿En cuál de los siguientes problemas es apropiada una solución heurística?
Encontrar el elemento más grande de una lista.
Encontrar la mejor combinación de ingredientes para la salsa de espagueti.
Jugar al ajedrez.
Encontrar la combinación de una cerradura de n números.
5.1.8
CSN-2.A part b, CSN-2.A.5
¿Cuánto tiempo tardará este programa secuencial en ejecutarse?
esperar (6), esperar (4), esperar (8)
18
8
4
6
5.1.8
CSN-2.A part b, CSN-2.A.6
¿Cuánto tiempo tardará este programa paralelo en ejecutarse?
enviar mensaje (ir) y esperar, esperar (6) segs enviar mensaje (ir): esperar (4) segs enviar mensaje (ir): esperar (8) segs
18
8
6
14
5.1.8
¿Cuál es la aceleración para esta solución paralela en comparación con la solución secuencial?
frac{18}{14}
frac{14}{18}
frac{18}{6}
frac{18}{8}

Laboratorio 3: Transformar datos en información

+
5.3.2
Los científicos que estudian las aves a menudo colocan etiquetas de rastreo a las aves migratorias. Para cada ave, los siguientes datos son recolectados regularmente en intervalos frecuentes: ¿Cuál de las siguientes preguntas sobre un ave en particular no puede ser respondida utilizando solo los datos recogidos de las etiquetas de rastreo?
Aproximadamente, ¿cuánto tiempo pasa el pájaro en el aire y en el suelo?
¿El pájaro viaja en grupos con otras aves rastreadas?
¿Se ve afectada la ruta migratoria del ave por los patrones de temperatura?
¿Cuáles son los efectos de la contaminación industrial en la ruta de migración del ave?
5.3.2
Usando computadoras, los investigadores a menudo buscan grandes conjuntos de datos para encontrar patrones interesantes en los datos. ¿Cuál de los siguientes no es un ejemplo donde la búsqueda de patrones es necesaria para reunir la información deseada?
Una empresa de compras en línea que analiza el historial de compras de los clientes para recomendar nuevos productos.
Una escuela secundaria que analiza los registros de asistencia de los estudiantes para determinar qué estudiantes deben recibir una advertencia disciplinaria.
Una compañía de evaluación de crédito que analiza el historial de compras de los clientes para identificar casos de robo de identidad.
Una universidad que analiza los resultados del GPA y el SAT de los estudiantes de secundaria para evaluar su potencial de éxito en la universidad.
5.3.2
Una empresa de alquiler de coches utiliza una aplicación para hacer un seguimiento de las tendencias de viaje de sus clientes. Los datos recolectados pueden ser filtrados y clasificados por localización geográfica, fecha y hora, millas recorridas, y tarifa cobrada por el viaje. ¿Cuál de los siguientes es menos probable de ser respondido solamente con la característica de tendencias?
Qué hora del día es la más ocupada para la compañía en una ciudad determinada.
Desde qué ubicación geográfica se originan los paseos más largos.
Cómo afecta la competencia con las compañías de taxis locales a los negocios en un distrito determinado.
Cuánto dinero fue ganado por la compañía en un mes determinado.
5.3.2
Una compañía de descargas de música en línea almacena información sobre las compras de canciones realizadas por sus clientes. Cada día, la siguiente información se hace pública en la base de datos del sitio web de la empresa. A continuación se muestra una porción de ejemplo de la base de datos. La base de datos está ordenada por fecha y título de la canción.
Día y fecha Título de la canción Ciudad Número de veces que fue comprada
lunes  07/10/17 Despacito Boston, MA 117
lunes  07/10/17 Malibu Chicago, IL 53
lunes  07/10/17 Malibu New York, NY 197
lunes  07/10/17 Bad Liar Anchorage, AK 11
martes 07/11/17 Despacito San Diego, CA 241
¿Cuál de los siguientes no puede ser determinado utilizando sola la información en la base de datos?
La canción que más se compra en una semana determinada.
La ciudad con menos compras en un día concreto.
El número total de ciudades en las que se compró una determinada canción en un mes determinado.
El número total de canciones compradas por un cliente particular durante el curso de un año determinado.
5.3.6
Una nueva compañía de telefonía móvil—sin que sus clientes lo sepan—graba periódicamente fragmentos aleatorios de sus conversaciones y considera las grabaciones como datos. Además, recoge los siguientes metadatos de las conversaciones:

¿Para cuál de los siguientes objetivos sería más útil analizar los datos en lugar de los metadatos?

Para determinar si alguno de sus usuarios estuvo presente en el momento y lugar de un delito.
Para determinar la hora del día, la aplicación se utiliza con mayor frecuencia en una determinada ubicación geográfica.
Para determinar el lenguaje que se utiliza con mayor frecuencia en las conversaciones de los usuarios.
Para determinar los usuarios más activos de la aplicación en un año determinado.
5.3.6
¿Cuál de los siguientes no es un ejemplo de metadatos?
Los datos sobre una imagen digital describen el tamaño de la imagen, la resolución de la imagen, la profundidad del color, y cuando se creó la imagen.
Los datos sobre un documento de texto que contienen información sobre la longitud del documento, su autor, la fecha en que se redactó el documento y un breve resumen del contenido.
Datos sobre una manada de lobos describiendo su entorno, sus hábitos de caza, su dieta y sus ciclos de sueño.
Datos sobre una página web que contenga una descripción del contenido de la página y una lista de palabras clave vinculadas al contenido.
\ No newline at end of file diff --git a/cur/programming/5-algorithms/unit-5-self-check.html b/cur/programming/5-algorithms/unit-5-self-check.html new file mode 100644 index 0000000000..26a61ba63c --- /dev/null +++ b/cur/programming/5-algorithms/unit-5-self-check.html @@ -0,0 +1,19 @@ + + + + + + + + + + +Unit 5 Self-Check Questions + + + + +

Unit 5: Algorithms and Simulations

+

Lab 1: Search Algorithms and Efficiency

+
5.1.3
AAP-2.P part b, AAP-2.P.2
In order to use a binary search, the data must be...
binary
sorted
unsorted
linear
5.1.3
Which of the following questions can be answered with a binary search, assuming the data are sorted? Check all that apply:
What is my friend Rasheed's phone number?
Give me a list of all the Beyoncé songs.
Tell me if bread is on my shopping list.
Who in my contact list lives on Grand Avenue?
5.1.5
The table below shows the computer time it takes to complete various tasks on the data of different sized towns.

Task Small Town
(population 1,000)
Mid-sized Town
(population 10,000)
Large Town
(population 100,000)
Entering Data 2 hours 20 hours 200 hours
Backing up Data 0.5 hours 5 hours 50 hours
Searching through Data 5 hours 15 hours 25 hours
Sorting Data 0.01 hour 1 hour 100 hours
Based on the information in the table, which of the following tasks is likely to take the longest amount of time when scaled up for a city of population 1,000,000.
Entering data
Backing up data
Searching through data
Sorting data
5.1.6
In which of the following problems is a heuristic solution appropriate?
Find the biggest item in a list.
Find the best combination of ingredients for spaghetti sauce.
Playing chess.
Find the combination to a lock with n numbers.
5.1.8
CSN-2.A part b, CSN-2.A.5
How long will this sequential program take to run?
wait (6), wait (4), wait (8)
18
8
4
6
5.1.8
CSN-2.A part b, CSN-2.A.6
How long will this parallel program take to run?
broadcast (go) and wait, wait (6) secs when I receive (go): wait (4) secs when I receive (go): wait (8) secs
18
8
6
14
5.1.8
What is the speedup for this parallel solution when compared to the sequential solution?
frac{18}{14}
frac{14}{18}
frac{18}{6}
frac{18}{8}

Lab 3: Turning Data into Information

+
5.3.2
Scientists studying birds often attach tracking tags to migrating birds. For each bird, the following data is collected regularly at frequent intervals: Which of the following questions about a particular bird could not be answered using only the data gathered from the tracking tags.
Approximately how much time does the bird spend in the air and on the ground?
Does the bird travel in groups with other tracked birds?
Is the migration path of the bird affected by temperature patterns?
What are the effects of industrial pollution on the migration path of the bird?
5.3.2
Using computers, researchers often search large data sets to find interesting patterns in the data. Which is of the following is not an example where searching for patterns is needed to gather desired information?
An online shopping company analyzing customers purchase history to recommend new products.
A high school analyzing student attendance records to determine which students should receive a disciplinary warning.
A credit scoring company analyzing purchase history of clients to identify cases of identity theft.
A college analyzing high school students’ GPA and SAT scores to assess their potential college success.
5.3.2
A car hailing company uses an app to track the travel trends of its customers. The data collected can be filtered and sorted by geographic location, time and date, miles traveled, and fare charged for the trip. Which of the following is least likely to be answerable using only the trends feature?
What time of the day is the busiest for the company at a given city.
From which geographical location do the longest rides originate.
How is competition with the local cab companies affecting business in a given district.
How much money was earned by the company in a given month.
5.3.2
An online music download company stores information about song purchases made by its customers. Every day, the following information is made publicly available on a company website database. An example portion of the database is shown below. The database is sorted by date and song title.
Day and Date Song Title City Number of Times Purchased
Mon 07/10/17 Despacito Boston, MA 117
Mon 07/10/17 Malibu Chicago, IL 53
Mon 07/10/17 Malibu New York, NY 197
Mon 07/10/17 Bad Liar Anchorage, AK 11
Tue 07/11/17 Despacito San Diego, CA 241
Which of the following cannot be determined using only the information in the database?
The song that is purchased the most in a given week.
The city with the fewest purchases on a particular day.
The total number of cities in which a certain song was purchased in a given month.
The total number of songs purchased by a particular customer during the course of a given year.
5.3.6
A new mobile phone company—unbeknownst to its customers—periodically records random snippets of their conversations and considers the recordings as data. In addition, it collects the following metadata on the conversations:

For which of the following goals would it be more useful to analyze the data instead of the metadata?

To determine if any of its users was present at the time and place of a crime.
To determine the time of day the app is used most frequently in a certain geographic location.
To determine the language most commonly used in user conversations.
To determine the most active users of the app for a given year.
5.3.6
Which of the following is not an example of metadata?
Data about a digital image describing the size of the image, image resolution, color depth, and when the image was created.
Data about a text document containing information about the length of the document, its author, the date the document was written, and a short summary of the content.
Data about a pack of wolves describing their habitat, hunting habits, diet, and sleep cycles.
Data about a web page containing a description of page content and a list of key words linked to the content.
\ No newline at end of file diff --git a/cur/programming/5-algorithms/unit-5-vocab.es.html b/cur/programming/5-algorithms/unit-5-vocab.es.html new file mode 100644 index 0000000000..77b95f3f46 --- /dev/null +++ b/cur/programming/5-algorithms/unit-5-vocab.es.html @@ -0,0 +1,18 @@ + + + + + + + + + + +Unidad 5 Vocabulario + + + + +

Unidad 5: Algoritmos y Simulaciones

+

Laboratorio 1: Algoritmos de búsqueda y eficiencia

+
5.1.2
AAP-4.A.1
5.1.2
5.1.3: Búsqueda binaria
AAP-2.P.1, AAP-2.P.2

Un algoritmo de búsqueda binaria comienza en medio de una lista ordenada y elimina repetidamente la mitad de la lista hasta que se encuentra el valor deseado o se han eliminado todos los elementos.

AAP-2.O.1
Aprendiste acerca de lista transpuesta en Unidad 2 Laboratorio 2 Página 3: Comprobación de cada respuesta del cuestionario.

La búsqueda lineal hace un recorrido completo de la lista. La búsqueda binaria ahorra tiempo al hacer un recorrido parcial de la lista.

5.1.4
AAP-4.A.3

La relación entre el tamaño de la entrada y el número de pasos requeridos para resolver un problema es la eficiencia del algoritmo utilizado para resolver el problema.

5.1.5
5.1.5
5.1.6
AAP-4.A.2
5.1.6
AAP-4.B.1, AAP-4.B.2, AAP-4.B.3

Un problema resoluble es un problema de decisión para el cual es posible escribir un algoritmo que dará una salida correcta para todas las entradas.

Un problema indecidible es lo opuesto.  No es posible escribir un algoritmo que dará una salida correcta para todas las entradas—aunque podría ser posible para algunos de ellos.

5.1.8
CSN-2.A.1, CSN-2.A.2

Esta sección cubre dos modelos de computación:

5.1.8
CSN-2.A.7

Los programadores se refieren a la aceleración de la solución paralela para describir cuántas veces más rápido se compara la solución paralela con la solución secuencial:
text{aceleración} = frac{text{tiempo secuencial}}{text{tiemo paralelo}}

5.1.8
CSN-2.A.3

Computación distribuida es una forma de computación paralela que utiliza múltiples computadoras (tal vez incluso se extienda por todo el mundo).

5.1.8

Un procesador es una pieza de circuitos dentro de una computadora que procesa las instrucciones de los programas de computación.

CPU

Créditos de la imagen: Wikipedia usuario Solipsist

Laboratorio 2: Simulaciones

5.2.1
AAP-3.F.1, AAP-3.F.2

Las simulaciones son representaciones por computadora de cosas o situaciones reales que varían con el tiempo. Una simulación es una abstracción diseñada para un propósito en particular.

Laboratorio 3: Transformar datos en información

5.3.1: datos vs. información
DAT-2.A.1

DAT-2.A.2
Los datos proporcionan oportunidades para identificar tendencias, establecer conexiones y abordar problemas. La información es el resultado del análisis de esos datos.

5.3.1

 Una correlación es un tipo particular de información, es decir, una dependencia entre dos variables en una situación. Por ejemplo, en la primera imagen aquí, mientras una variable sube, la otra baja. También es una correlación cuando una variable sube o baja y la otra cambia de la misma manera.

Un gráfico con un montón de puntos de datos, en el cual generalmente siguen una línea recta desde la parte superior izquierda hasta la parte inferior derecha
Un gráfico con un montón de puntos de datos, en el cual generalmente siguen una línea recta desde la parte inferior izquierda hasta la parte superior derecha
Un gráfico con un montón de puntos de datos dispersos por todas partes, sin seguir una línea
correlación negativa
correlación positiva 
no hay correlación
5.3.1
DAT-2.E.4

Insight es una conclusión significativa extraída del análisis de la información.

5.3.3 Animación de tres fotogramas del reporte del conjunto de datos de automóviles presentado como una tabla con columnas y filas; en el primer fotograma, se destaca la cuarta fila de la tabla y se etiqueta como 'registro (fila)'; en el segundo fotograma, se destaca la tercera columna de la tabla y se etiqueta como 'columna'; en el tercer fotograma, se destaca la celda en la cuarta fila y tercera columna y se etiqueta como 'campo'
5.3.3
DAT-2.C.4, DAT-2.E.2

Limpieza de datos es el proceso de hacer los datos uniformes sin cambiar su significado (como el reemplazo de abreviaturas, ortografía y mayúsculas por la palabra deseada o la conversión de millas a kilómetros). Los programadores pueden utilizar programas para filtrar y limpiar los datos digitales, obteniendo así una mayor visión y conocimiento.

5.3.5
DAT-2.E.3 solamente clasificando

Clasificar los datos es extraer grupos de datos con una característica en común.

5.3.5

El modo de un conjunto de datos es el valor que aparece con más frecuencia.

5.3.6
DAT-2.B.1

Los metadatos son datos sobre datos. Por ejemplo, el dato puede ser una imagen, mientras que los metadatos pueden incluir la fecha de creación o el tamaño del archivo de la imagen.

Laboratorio 4: Problemas irresolubles e indecidibles

5.4.1

Una declaración indecidible puede ser verdadera o falsa; no sabemos cuál.

Una declaración autocontradictoria no puede ser verdadera ni falsa.

5.4.1

Una prueba por contradicción es una prueba de dos pasos para saber si algo es falso que se realiza:

  1. asumiendo que es verdad
  2. mostrando cómo eso es imposible (que crea una contradicción)
5.4.2

Un bucle infinito es una secuencia de instrucciones de computadora que se repite para siempre.

Un problema irresoluble es aquel para el que nunca se puede escribir un algoritmo para encontrar la solución.

Un problema indecidible es aquel para el que nunca se puede escribir un algoritmo que siempre dé una decisión verdadero/falso correcta para cada valor de entrada. Los problemas indecidibles son una subcategoría de problemas irresolubles que incluyen solo problemas que deberían tener una respuesta sí/no (como: ¿mi código tiene un error?).

\ No newline at end of file diff --git a/cur/programming/5-algorithms/unit-5-vocab.html b/cur/programming/5-algorithms/unit-5-vocab.html new file mode 100644 index 0000000000..38ffb5bb28 --- /dev/null +++ b/cur/programming/5-algorithms/unit-5-vocab.html @@ -0,0 +1,18 @@ + + + + + + + + + + +Unit 5 Vocabulary + + + + +

Unit 5: Algorithms and Simulations

+

Lab 1: Search Algorithms and Efficiency

+
5.1.2: Problem and Instance of a Problem
AAP-4.A.1
5.1.2: Linear Search or Sequential Search
5.1.3: Binary Search
AAP-2.P.1, AAP-2.P.2

A binary search algorithm starts in the middle of a sorted list and repeatedly eliminates half the list until either the desired value is found or all elements have been eliminated.

AAP-2.O.1
You learned about traversing a list on Unit 2 Lab 2 Page 3: Checking Each Quiz Answer.

Linear search does a complete traversal of the list. Binary search saves time by doing a partial traversal of the list.

5.1.4
AAP-4.A.3

The relationship between the input size and the number of steps required to solve a problem is the efficiency of the algorithm used to solve the problem.

5.1.5
5.1.5
5.1.6
AAP-4.A.2
5.1.6
AAP-4.B.1, AAP-4.B.2, AAP-4.B.3

A decidable problem a decision problem for which it's possible to write an algorithm that will give a correct output for all inputs.

An undecidable problem is the opposite. It's not possible to write an algorithm that will give a correct output for all inputs—even though it might be possible for some of them.

5.1.8: Sequential and Parallel Computing
CSN-2.A.1, CSN-2.A.2

This section covers two computational models:

5.1.8
CSN-2.A.7

Programmers refer to the speedup of parallel solution to describe how many times as fast the parallel solution is compared to the sequential solution:
text{speedup} = frac{text{sequential time}}{text{parallel time}}

5.1.8
CSN-2.A.3

Distributed computing is a form of parallel computing that uses multiple computers (perhaps even spread out around the world).

5.1.8

A processor is a piece of circuitry inside a computer that processes the instructions from computer programs.

CPU

Image credit: Wikipedia user Solipsist

Lab 2: Simulations

5.2.1
AAP-3.F.1, AAP-3.F.2

Simulations are computer representations of real things or situations that vary over time. A simulation is an abstraction designed for a particular purpose.

Lab 3: Turning Data into Information

5.3.1: Data vs. Information
DAT-2.A.1

DAT-2.A.2
Data provide opportunities for identifying trends, making connections, and addressing problems. Information is the result of analyzing that data.
5.3.1

A correlation is a particular kind of information, namely a dependence between two variables. For example in the first picture here, as one variable goes up the other goes down. It's also a correlation when as one variable goes up or down the other changes in the same manner.

a graph with a bunch of data points, in which they generally follow a straight line from top left to bottom right
a graph with a bunch of data points, in which they generally follow a straight line from bottom left to top right
a graph with a bunch of data points scattered all over the place, not following a line
negative correlation
positive correlation
no correlation
5.3.1
DAT-2.E.4

Insight is a meaningful conclusion drawn from analyzing information.

5.3.3: Records, Fields, and Columns three frame animation of the report of cars dataset displayed as a table with columns and rows; in the first frame, the fourth row of the table is highlighted and labeled 'record (row)'; in the second frame, the third column of the table is highlighted and labeled 'column'; in the third frame, the cell in the fourth row and third column is highlighted and labeled 'field'
5.3.3
DAT-2.C.4, DAT-2.E.2

Cleaning data is the process of making the data uniform without changing its meaning (such as replacing abbreviations, spellings, and capitalizations with the intended word or converting miles to kilometers). Programmers can use programs to filter and clean digital data, thereby gaining insight and knowledge.

5.3.5
DAT-2.E.3 classifying only

Classifying data means distributing data into groups based on common characteristics.

5.3.5

The mode of a data set is the value that appears most often in it.

5.3.6
DAT-2.B.1

Metadata are data about data. For example, the piece of data may be an image, while the metadata may include the date of creation or the file size of the image.

Lab 4: Unsolvable and Undecidable Problems

5.4.1

An undecidable statement might be true or might be false; we don't know which.

A self-contradictory statement can be neither true nor false.

5.4.1

A proof by contradiction is a two-step proof that a statement is false, which is done by

  1. assuming the statement is true
  2. based on that assumption, proving something known to be false (that is, showing the assumption creates a contradiction)
5.4.2

An infinite loop is a sequence of computer instructions that repeats forever.

An unsolvable problem is one for which no algorithm can ever be written to find the solution.

An undecidable problem is one for which no algorithm can ever be written that will always give a correct true/false decision for every input value. Undecidable problems are a subcategory of unsolvable problems that include only problems that should have a yes/no answer (such as: does my code have a bug?).

\ No newline at end of file diff --git a/cur/programming/6-computers/unit-6-self-check.es.html b/cur/programming/6-computers/unit-6-self-check.es.html new file mode 100644 index 0000000000..0e90cd05d3 --- /dev/null +++ b/cur/programming/6-computers/unit-6-self-check.es.html @@ -0,0 +1,17 @@ + + + + + + + + + + +Unidad 6 Preguntas de Autocomprobacion + + +

Unidad 6: ¿Cómo funcionan las computadoras?

+

Laboratorio 1: Jerarquía de abstracción computacional

+
6.1.3
Este código es similar a un procedimiento de orden superior que has aprendido. Habla con tu compañero Identifica el procedimiento que este código imita:
variables de programa (resultado) (índice); fijar el parámetro (resultado) a (lista); fijar el parámetro (índice) a (0); repetir (longitud de (palabras)){incrementar (índice) en (1); añadir (unir (elemento (índice) de (palabras)) s) a (resultado)}; reportar (resultado)
para cada (palabra) de (palabra) {reportar ((unir (palabra) (s)))}
reportar (mantener los elementos donde (unir () (s)) de (palabras))
reportar (mapear (unir () (s)) sobre (palabras))
reportar (combinar los elementos de (unir () (s)) con (palabras))
6.1.3
¿Cuáles de las siguientes afirmaciones son correctas sobre un lenguaje de programación de bajo nivel en comparación con un lenguaje de programación de alto nivel?
  1. Los programas de lenguaje de bajo nivel son generalmente más difíciles de entender para las personas, que los programas escritos en un lenguaje de alto nivel.
  2. Un lenguaje de bajo nivel proporciona a los programadores más abstracciones que un lenguaje de alto nivel.
  3. Los programas de lenguaje de bajo nivel son generalmente más difíciles de depurar que los programas escritos en un lenguaje de alto nivel.
I solamente.
I y III solamente.
II y III solamente.
I, II, y III.
6.1.3
Un programa está escrito en un lenguaje de programación de alto nivel. Identifica la declaración correcta sobre el programa.
El programa también puede ser escrito en lenguaje de máquina usando código binario, pero entonces será menos fácil de entender por la personas.
El programa también puede ser escrito en lenguaje de máquina usando código binario, lo que disminuirá la posibilidad de errores.
El programa no puede ser escrito en código binario, ya que solo los datos pueden ser representados utilizando la notación binaria.
Partes simples del programa pueden ser escritas en código binario, pero los elementos de control como los condicionales, los bucles deben ser expresados en un lenguaje de programación de alto nivel.
6.1.9
¿Cuál de las siguientes expresiones reporta verdadero?
  1. (verdadero y falso) y (no (verdadero y falso))
  2. (no (verdadero o falso)) o (verdadero o falso)
I solamente
II solamente
I y II
Ni I ni II
6.1.9
¿Cuál de los siguientes circuitos lógicos reportará? ¿verdadero? (T representa Verdadero y F representa falso.)
    Este problema es probablemente más difícil que algo que verás en el examen, así que si puedes con este, ¡lo estás haciendo muy bien!
  1. diagrama de compuerta lógica de (no ((T y F)) o (T y F))
  2. diagrama de compuerta lógica de ((T o F) y (no (T o F)))
I solamente
II solamente
I y II
Ni I ni II

Laboratorio 2: Historia e impacto de las computadoras

+
6.2.2
Como Gordon Moore observó en 1965, los datos muestran que las velocidades de procesamiento por computadora se duplican aproximadamente cada dos años. Las empresas de tecnología utilizan esta observación, ahora conocida como "Ley de Moore", en su planificación. De lo siguiente, identifica cuál describe mejor cómo las empresas de tecnología pueden utilizar la Ley de Moore en la planificación.
Pueden esperar duplicar sus ganancias cada dos años.
Pueden anticipar las fechas precisas en que estarán disponibles los últimos avances informáticos y, por lo tanto, planificar con precisión sus productos con anticipación.
Pueden basar sus objetivos de Investigación y Desarrollo en las velocidades de procesamiento futuras esperadas.
Pueden esperar que sus costos se dupliquen con cada aumento en la velocidad del procesador.
\ No newline at end of file diff --git a/cur/programming/6-computers/unit-6-self-check.html b/cur/programming/6-computers/unit-6-self-check.html new file mode 100644 index 0000000000..ce4b740e64 --- /dev/null +++ b/cur/programming/6-computers/unit-6-self-check.html @@ -0,0 +1,17 @@ + + + + + + + + + + +Unit 6 Self-Check Questions + + +

Unit 6: How Computers Work

+

Lab 1: Computer Abstraction Hierarchy

+
6.1.3
This code is similar to a higher-order procedure that you have learned. Talk with Your Partner Identify the procedure that this code imitates:
script variables (result) (index); set result to (list); set index to (0); repeat (length of (words)){ change index by (1); add (join (item (index) of (words)) s) to (result)}; report (result)
for each (word) of (words) {report ((join (word) (s)))}
report (keep items such that (join () (s)) from (words))
report (map (join () (s)) over (words))
report (combine with (join () (s)) items of (words))
6.1.3
Which of the following statements are correct about a low-level programming language compared with a high-level programming language?
  1. Low-level language programs are generally harder for people to understand than programs written in a high-level language.
  2. A low-level language provides programmers with more abstractions than a high-level language.
  3. Low-level language programs are generally harder to debug than programs written in a high-level language.
I only.
I and III only.
II and III only.
I, II, and III.
6.1.3
A program is written in a high-level programming language. Identify the correct statement about the program?
The program can also be written in machine language using binary code, but then it will be less easily understood by people.
The program can also be written in machine language using binary code, which will decrease the possibility of mistakes.
The program cannot be written in binary code as only data can be represented by using binary notation.
Simple parts of the program can be written in binary code, but control elements such as conditionals, loops must be expressed in a high-level programming language.
6.1.9
Which of the following expressions will report true?
  1. (T and F) and (not (T and F))
  2. (not (T or F)) or (T or F)
I only
II only
I and II
Neither I nor II
6.1.9
Which of the following logic circuits will report true? (T stands for true, and F stands for false.)
    This problem is probably harder than something you'll see on the exam, so if you can get this one, you are doing great!
  1. logic gate diagram of (not ((T and F)) or (T and F))
  2. logic gate diagram of ((T or F) and (not (T or F)))
I only
II only
I and II
Neither I nor II

Lab 2: History of Computers

+
6.2.2
As Gordon Moore observed in 1965, data show that computer processing speeds roughly double every two years. Technology companies use this observation, now known as "Moore’s Law,’ in their planning. From the following, identify which one best describes how technology companies can use Moore’s Law in planning.
They can expect to double their profits every two years.
They can anticipate the precise dates when the latest computing advancements will be available and therefore accurately plan their products in advance.
They can base their R&D (Research and Development) targets on expected future processing speeds.
They can expect their costs to double with each increase in processor speed.
\ No newline at end of file diff --git a/cur/programming/6-computers/unit-6-vocab.es.html b/cur/programming/6-computers/unit-6-vocab.es.html new file mode 100644 index 0000000000..b110a3cd29 --- /dev/null +++ b/cur/programming/6-computers/unit-6-vocab.es.html @@ -0,0 +1,16 @@ + + + + + + + + + + +Unidad 6 Vocabulario + + +

Unidad 6: ¿Cómo funcionan las computadoras?

+

Laboratorio 1: Jerarquía de abstracción computacional

+
6.1.1 Vocabulario: análogo vs. digital

Digital y análogo son conceptos opuestos. Digital significa información que es representada en unos y ceros. Análogo significa información que es representada por señales que varían constantemente (es decir, que incluyen los valores intermedios).

6.1.4: Bibliotecacs de software
AAP-3.D.1, AAP-3.D.2, AAP-3.D.3
6.1.6

Lenguaje de máquina es el lenguaje de programación de más bajo nivel; es entendido directamente por el hardware de la computadora.

Arquitectura es una abstracción, una especificación del lenguaje de máquina. También indica cómo se conecta el procesador a la memoria. No especifica la circuitería; la misma arquitectura se puede construir como circuitería de muchas maneras diferentes.

6.1.8

Un circuito integrado ("CI" or "chip") es un dispositivo físico individual que contiene millones o miles de millones de partes eléctricas básicas. Un procesador es un IC, pero no todos los procesadores son CI; También hay chips de proposito especial dentro de una computadora.

Laboratorio 2: Historia e impacto de las computadoras

6.2.2

La Ley de Moore es la predicción de que la cantidad de transistores en un chip se duplica cada año.

\ No newline at end of file diff --git a/cur/programming/6-computers/unit-6-vocab.html b/cur/programming/6-computers/unit-6-vocab.html new file mode 100644 index 0000000000..fbcc02455f --- /dev/null +++ b/cur/programming/6-computers/unit-6-vocab.html @@ -0,0 +1,16 @@ + + + + + + + + + + +Unit 6 Vocabulary + + +

Unit 6: How Computers Work

+

Lab 1: Computer Abstraction Hierarchy

+
6.1.1: analog vs. digital

Digital and analog are opposites. Digital means information that is represented as ones and zeros. Analog means information that is represented by signals that vary continuously (that is, including in-between values).

6.1.4: Software Libraries
AAP-3.D.1, AAP-3.D.2, AAP-3.D.3
6.1.6

Machine language is the lowest-level programming language; it is directly understood by the computer hardware.

Architecture is an abstraction, a specification of the machine language. It also tells how the processor connects to the memory. It doesn't specify the circuitry; the same architecture can be built as circuitry in many different ways.

6.1.8

An integrated circuit ("IC" or "chip") is a single physical device that contains millions or billions of basic electrical parts. A processor is an IC, but not all ICs are processors; there are also special-purpose chips inside a computer.

Lab 2: History of Computers

6.2.2

Moore's Law is the prediction that the number of transistors that fit on one chip doubles every year.

\ No newline at end of file diff --git a/cur/programming/7-recursion/unit-7-self-check.es.html b/cur/programming/7-recursion/unit-7-self-check.es.html new file mode 100644 index 0000000000..f922510eb0 --- /dev/null +++ b/cur/programming/7-recursion/unit-7-self-check.es.html @@ -0,0 +1,18 @@ + + + + + + + + + + +Unidad 7 Preguntas de Autocomprobacion + + + + +

Unidad 7: Fractales y Recursión

+

Laboratorio 1: Árboles

+
7.1.3
Un árbol con tronco y cuatro niveles de ramas

Si se dibuja esta imagen, ¿qué número debe estar en la ranura de entrada nivel?

En otras palabras, ¿qué va en el espacio en blanco del código anterior para hacer esta imagen?

6
1
5
4
7.1.3

¿Qué sucedería si cambiara el tamaño de entrada a -100?

El programa nunca dejará de ejecutarse y se dibujarán muchas ramas diferentes.
Nunca dejará de funcionar y solo se dibujará una sola rama.
Funcionará como si el tamaño fuera +100.
La imagen se volteará al revés, pero por lo demás tendrá el mismo aspecto.
No se dibujará nada.
7.1.3

¿Qué sucedería si cambiara el nivel de entrada a -4?

El programa nunca dejará de ejecutarse, pero dibujará un árbol que parece un árbol con ramas cada vez más pequeñas.
Nunca dejará de correr y la imagen será una espiral hacia la izquierda con el objeto dando vueltas en el aire.
Funcionará como si el nivel fuera +4.
La imagen se volteará al revés, pero por lo demás tendrá el mismo aspecto.
No se dibujará nada.
7.1.4
Árbol con tronco y cuatro niveles de ramas inclinadas hacia la izquierda

¿Qué ha cambiado en el código?

La cantidad de giro entre ramas.
El factor de escala (cuánto disminuye la longitud cada vez).
Se añadieron llamadas recursivas adicionales a la función y otras cosas de ángulo para que todo funcione.
7.1.4
Árbol con cuatro ramas en lugar de dos que se dividan en cada nivel

¿Qué ha cambiado en el código?

La cantidad de giro entre ramas.
El factor de escala (cuánto disminuye la longitud cada vez).
Agregamos llamadas recursivas adicionales a la función y otras cosas de ángulo para que todo funcione.
7.1.4
Árbol con ramas cada vez más alargadas

¿Qué ha cambiado en el código?

La cantidad de giro entre ramas.
Cambiamos el factor de escala (cuánto disminuye la longitud cada vez).
Se añadieron llamadas recursivas adicionales a la función y otras cosas de ángulo para que todo funcione.
7.1.4
Árbol con ramas del mismo tamaño

¿Qué ha cambiado en el código?

La cantidad de giro entre sucursales.
El factor de escala (cuánto disminuye la longitud cada vez).
Se añadieron llamadas recursivas adicionales a la función y otras cosas de ángulo para que todo funcione.
7.1.4
Árbol con ramas con el ángulo correcto

¿Qué ha cambiado en el código?

La cantidad de giro entre cada sucursal.
El factor de escala (cuánto disminuye la longitud cada vez).
Se añadieron llamadas recursivas adicionales a la función y otras cosas de ángulo para que todo funcione.
\ No newline at end of file diff --git a/cur/programming/7-recursion/unit-7-self-check.html b/cur/programming/7-recursion/unit-7-self-check.html new file mode 100644 index 0000000000..2b7ff8087c --- /dev/null +++ b/cur/programming/7-recursion/unit-7-self-check.html @@ -0,0 +1,18 @@ + + + + + + + + + + +Unit 7 Self-Check Questions + + + + +

Unit 7: Fractals and Recursion

+

Lab 1: Trees

+
7.1.3
A tree with trunk and four levels of branches If this picture is drawn, what number must be in the level input slot of the tree procedure?
6
1
5
4
7.1.3
What would happen if you changed the input size to be -100? (Don't use Snap!. The point is to think about it.)
The program will never stop running and a lot of different branches will be drawn.
It will never stop running and only a single branch will be drawn.
It will work just as if the size were positive 100.
The image will be flipped upside down but will otherwise look the same.
Nothing will be drawn.
7.1.3
What would happen if you changed the input level to be -4? (Don't use Snap!. The point is to think about it.)
The program will never stop running, but it will draw a tree-looking tree with more and more smaller and smaller branches.
It will never stop running, and the picture will be a leftward spiral with the sprite spinning around in midair.
It will work just as if the level were positive 4.
The image will be flipped upside down but will otherwise look the same.
Nothing will be drawn.
7.1.4
Tree with trunk and four levels of branches swaying to the left

What was changed in the code?

The turn amount between branches
The scaling factor (how much the length decreases each time)
Additional recursive calls to the function and additional turn blocks
7.1.4
Tree with four branches instead of two splitting at each level

What was changed in the code?

The turn amount between branches
The scaling factor (how much the length decreases each time)
Additional recursive calls to the function and additional turn blocks
7.1.4
Tree with longer and longer branches

What was changed in the code?

The turn amount between branches
The scaling factor (how much the length decreases each time)
Additional recursive calls to the function and additional turn blocks
7.1.4
Tree with same-size branches

What was changed in the code?

The turn amount between branches
The scaling factor (how much the length decreases each time)
Additional recursive calls to the function and additional turn blocks
7.1.4
Tree with right angle branches

What was changed in the code?

The turn amount between branches
The scaling factor (how much the length decreases each time)
Additional recursive calls to the function and additional turn blocks
\ No newline at end of file diff --git a/cur/programming/7-recursion/unit-7-vocab.es.html b/cur/programming/7-recursion/unit-7-vocab.es.html new file mode 100644 index 0000000000..eed4fe9beb --- /dev/null +++ b/cur/programming/7-recursion/unit-7-vocab.es.html @@ -0,0 +1,18 @@ + + + + + + + + + + +Unidad 7 Vocabulario + + + + +

Unidad 7: Fractales y Recursión

+

Laboratorio 1: Árboles

+
7.1.1

Transparencia del estado: volver a poner todo (objeto, lápiz, etc.) exactamente como estaba cuando comenzaste, es importante cuando los bloques dependen de otros bloques. Por lo general, esto significa devolver el objeto a la misma posición y dirección, y el lápiz al mismo color y tamaño que tenían.

7.1.1

Usar un bloque dentro de sí mismo se llama recursividad.

Aprendiste sobre la recursividad en Unidad 3 Laboratorio 1 Página 3: Usar la abstracción para anidar triángulos.
7.1.1

Un fractal es un patrón repetido infinito formado por copias (o ligeras variaciones) de la misma forma. En esta imagen, la rama verde tiene (esencialmente) la misma forma que la imagen completa.

7.1.2

Esta versión diferente para el nivel más bajo de un script recursivo se denomina caso base.

\ No newline at end of file diff --git a/cur/programming/7-recursion/unit-7-vocab.html b/cur/programming/7-recursion/unit-7-vocab.html new file mode 100644 index 0000000000..510b87b9aa --- /dev/null +++ b/cur/programming/7-recursion/unit-7-vocab.html @@ -0,0 +1,18 @@ + + + + + + + + + + +Unit 7 Vocabulary + + + + +

Unit 7: Fractals and Recursion

+

Lab 1: Trees

+
7.1.1

State transparency means putting everything back exactly as it was when you started. It is especially important when blocks depend on other blocks. Usually, this means returning the sprite to the same position and direction and returning the pen to the same color and size.

7.1.1

Using a procedure inside of itself is called recursion.

You learned about recursion on Unit 3 Lab 1 Page 3: Using Abstraction to Nest Triangles.
7.1.1

A fractal is an infinite repeating pattern made up of copies (or slight variations) of the same shape. In this picture, the green branch is (essentially) the same shape as the entire picture.

7.1.2

This different version for the lowest level of a recursive script is called the base case.

\ No newline at end of file diff --git a/cur/programming/8-recursive-reporters/unit-8-vocab.html b/cur/programming/8-recursive-reporters/unit-8-vocab.html new file mode 100644 index 0000000000..989ff18fdd --- /dev/null +++ b/cur/programming/8-recursive-reporters/unit-8-vocab.html @@ -0,0 +1,18 @@ + + + + + + + + + + +Unit 8 Vocabulary + + + + +

Unit 8: Recursive Functions

+

Lab 3: Subsets

+
8.3.1

A subset is a selection of items from a set; it can be none, all, or any number in between.

\ No newline at end of file diff --git a/cur/programming/atwork.es.html b/cur/programming/atwork.es.html new file mode 100644 index 0000000000..9bc72e6839 --- /dev/null +++ b/cur/programming/atwork.es.html @@ -0,0 +1,20 @@ + + + + + + + + + + +El Científico de la Computación @ Acción + + + + +
2.1.3

Jerry Lawson (1940-2011) fue un ingeniero electrónico estadounidense y el pionero de los videojuegos, conocido como el "padre del cartucho de videojuegos". Nacido en la ciudad de Nueva York, Jerry tomó clases tanto en el Queens College como en el City College of New York. Mientras trabajaba como ingeniero jefe de hardware en Fairchild Semiconductor, lideró el desarrollo de la consola Channel F y fue pionero en la tecnología del cartucho de videojuegos, que se popularizó con Atari 2600.

Artículo: Uno de los pioneros más importantes de Silicon Valley del que nunca has oído hablar

+
3.1.6 fotografía de Grace Hopper

Grace Hopper (1906-1992) fue una contralmirante de la Marina de los Estados Unidos y pionera de la programación informática. Es mejor conocida por sus contribuciones pioneras a la programación de computadoras, el desarrollo de software y el diseño e implementación de lenguajes de programación.

60 Minutos: Grace Hopper

Uno de los primeros casos de "depuración" fue cuando una polilla real quedó atrapada dentro de una computadora con la que Grace Hopper estaba trabajando en 1947. Aquí hay una página de su cuaderno con la polilla pegada.

Foto del primer caso actual de error encontrado, lugar: Mark II Aiken Relay Calculator, Harvard, 1947
+
4.1.2 foto de Thomas Petite

Thomas (David) Petite (nacido en 1956) es miembro de la Tribu Fond du Lac de los Chippewa del Lago Superior. David es conocido por su trabajo en dispositivos habilitados para conexiones inalámbricas. Es uno de los primeros inventores de las redes inalámbricas ad hoc, un tipo de red inalámbrica temporal y descentralizada que permite que todos los teléfonos móviles funcionen hoy en día. Sus inventos también fueron una fuerza impulsora detrás del desarrollo de lo que ahora se conoce como la "Red Inteligente", la cual monitorea y aprovecha el poder de los dispositivos habilitados para conexiones inalámbricas en una ubicación específica.

Aprender más

4.1.3
photo of Vint Cert

Vint Cerf (nacido en 1943) es un pionero de Internet de EE. UU. y es reconocido como uno de "los padres de Internet". Vint Cerf, junto con Bob Kahn, co-desarrolló TCP/IP, un marco para organizar el conjunto de protocolos de comunicación utilizados en Internet y redes informáticas similares. Cerf también ha sido miembro de la Junta de Síndicos de la Gallaudet University, una universidad para la educación de personas sordas y con dificultades auditivas. Cerf mismo tiene dificultades auditivas y utiliza audífonos.

Artículo: Alza la voz: la tecnología ha transformado la comunidad sorda (en inglés)

4.2.4
Foto de Luis von Ahn
Imagen del usuario de Wikimedia EneasMx

Luis von Ahn (nacido en 1978), uno de los pioneros del crowdsourcing, es un emprendedor guatemalteco con un doctorado en informática. Si alguna vez tuviste que hacer clic en un encasillado o identificar imágenes para confirmar que no eres un robot, has utilizado tecnología basada en el trabajo de la empresa de seguridad digital reCAPTCHA de Ahn. reCAPTCHA protege los sitios web del fraude y el abuso con una interrupción mínima de la experiencia del usuario. Después de vender reCAPTCHA a Google en 2009, cofundó la popular plataforma de aprendizaje de idiomas Duolingo, que en 2020 tenía más de 500 millones de estudiantes en 39 idiomas.

Artículo: 'Solo quiero tener un impacto' (en inglés)

4.2.6
foto de Nicola Whiting
Imagen proporcionada para publicación con permiso de Nicola Whiting

Nicola Whiting es una diseñadora de joyas convertida en experta en ciberseguridad. Desde 2011, ha trabajado para Titania, líder a nivel mundial en ciberseguridad que se especializa en detectar problemas de seguridad y cumplimiento en redes. Whiting ha contribuido a liderar a Titania desde ser una ambiciosa startup hasta convertirse en la reconocida empresa que es hoy en día. Whiting también forma parte del consejo de NeuroCyber, una compañía que educa al público sobre cómo la neurodiversidad (por ejemplo, el trastorno del espectro autista, el TDAH y otras diferencias cerebrales) es beneficiosa para el progreso en ciberseguridad, y ayuda a desarrollar culturas de apoyo a través de políticas y prácticas para personas neurodivergentes.

Artículo escrito por Nicola Whiting: Todas las voces en la mesa: los beneficios de la diversidad (en inglés)

+
5.5.3
foto de Mary Golda Ross
Imagen del Museum of Women Pilots

Mary Golda Ross (1908-2008) fue una destacada ingeniera nativa americana y la primera mujer empleada por Lockheed, una corporación estadounidense de tecnología aeroespacial. A Ross le apasionaba la enseñanza a mujeres y nativos americanos, y pasó más de diez años enseñando mientras completaba su maestría en Matemáticas durante los veranos. Lockheed la contrató como matemática en 1942. Durante sus más de treinta años en dicha corporación, Ross contribuyó a la realización de diseños aeroespaciales de vanguardia, incluidos conceptos para viajes espaciales interplanetarios, vuelos tripulados y no tripulados en órbita terrestre, y satélites en órbita.

Artículo: Aerospace Engineer, Educator, and Advocate [Ingeniera aeroespacial, educadora y defensora]

+ \ No newline at end of file diff --git a/cur/programming/atwork.html b/cur/programming/atwork.html new file mode 100644 index 0000000000..7cd9791f61 --- /dev/null +++ b/cur/programming/atwork.html @@ -0,0 +1,22 @@ + + + + + + + + + + +Computer Scientists @ Work + + + + +
3.1.6 photo of Grace Hopper

Grace Hopper (1906-1992) was an United States Navy rear admiral and pioneer of computer programming. She is best known for her trailblazing contributions to computer programming, software development, and the design and implementation of programming languages.

60 Minutes: Grace Hopper

One early case of "debugging" was when an actual moth got stuck inside a computer Grace Hopper was working with in 1947. Here is a page from her notebook with the moth pasted in.

Photo of the first actual case of bug being found, at Mark II Aiken Relay Calculator, Harvard, 1947
+
4.1.2 photo of Thomas Petite

Thomas (David) Petite (born 1956) is a member of the Fond du Lac Band of the Lake Superior Chippewa tribe. David is best known for his work on wireless enabled devices. He is one of the early inventors of the wireless ad hoc networks, a temporary decentralized type of wireless network that enables all mobile phones to work today. His inventions were also a driving force behind the development of what is now known as the "Smart Grid" which monitors and harnesses the power of wireless-enabled devices at a specific location.

Learn More

4.1.3
photo of Vint Cert

Vint Cerf (born 1943) is an American Internet pioneer and is recognized as one of "the fathers of the Internet." Vint Cerf, along with Bob Kahn, co-developed TCP/IP, a framework for organizing the set of communication protocols used in the Internet and similar computer networks. Cerf has also served on the Board of Trustees of Gallaudet University, a university for the education of the deaf and hard-of-hearing. Cerf himself is hard of hearing and wears hearing aids.

Article: Sound Off: Technology Has Transformed the Deaf Community

4.2.4
photo of Luis von Ahn
Image from Wikimedia user EneasMx

Luis von Ahn (born in 1978), one of the pioneers of crowdsourcing, is a Guatemalan computer scientist and entrepreneur. If you've ever had to click a box or identify images to confirm you are not a robot, you've used technology based on the work of Ahn's digital security company reCAPTCHA. reCAPTCHA protects websites from fraud and abuse with minimal disruption to user experience. After selling reCAPTCHA to Google in 2009, he co-founded the popular language learning platform Duolingo, which as of 2020 had over 500 million learners across 39 languages.

Article: 'I Just Want to Have an Impact'

4.2.6
photo of Nicola Whiting
Image provided for publication with permission from Nicola Whiting

Nicola Whiting MBE, is an award winning jewelry designer and author, turned cybersecurity expert. She is co-owner of Titania group, which she helped lead from a 3 person start up, to a world-wide leader in cybersecurity, specializing in tools that detect network security and compliance issues. Whiting serves on multiple boards focused on increasing diversity in Cyber Security with the aim of reducing group-think and accelerating innovation & organizational resilience. e.g. She is a key spokesperson for NeuroCyber, an organization whose mission is ensuring neurodivergent people (those who process information differently due to brain differences such as Autism, ADHD, Dyslexia etc) can thrive - through building "inclusion by design" into workplace culture, policy and practice.

Article by Nicola Whiting: All the Voices at the Table: the Benefits of Diversity

+
5.5.3
photo of Mary Golda Ross
Image from Museum of Women Pilots

Mary Golda Ross (1908–2008) was a ground-breaking Native American engineer and the first female employed by Lockheed, an American aerospace technology corporation. Ross was passionate about educating women and Native Americans and spent over ten years teaching while earning her Master’s degree in mathematics during the summer. Lockheed hired her as a mathematician in 1942. During her thirty-plus years there, Ross contributed to cutting-edge aerospace designs including concepts for interplanetary space travel, crewed and uncrewed Earth-orbiting flights, and orbiting satellites.

Article: Aerospace Engineer, Educator, and Advocate

+ + + + \ No newline at end of file diff --git a/cur/programming/vocab-index.es.html b/cur/programming/vocab-index.es.html new file mode 100644 index 0000000000..2c576b4863 --- /dev/null +++ b/cur/programming/vocab-index.es.html @@ -0,0 +1,309 @@ + + + + + + + + + + + Índice currículo de BJC + + + + + + +
+
+ + \ No newline at end of file diff --git a/cur/programming/vocab-index.html b/cur/programming/vocab-index.html new file mode 100644 index 0000000000..92076fa0d2 --- /dev/null +++ b/cur/programming/vocab-index.html @@ -0,0 +1,331 @@ + + + + + + + + + + + BJC Curriculum Index + + + + + + +
+
+ + \ No newline at end of file diff --git a/sparks/student-pages/U1/unit-1-vocab.html b/sparks/student-pages/U1/unit-1-vocab.html new file mode 100644 index 0000000000..ca57757e74 --- /dev/null +++ b/sparks/student-pages/U1/unit-1-vocab.html @@ -0,0 +1,20 @@ + + + + + + + + + + +Unit 1 Vocabulary + + + + + + +

Unit 1: Functions and Data

+

Lab 1: Introduction to Snap!

+
1.1.1
1.1.1

A block is a piece of code. If you click a block, the computer will run the code.

Lab 2: Super Short Stories

1.2.5: Abstraction

Will they be watching a video on abstraction here? Or does Dan mention it in welcome? It feels so..abstract..here that I wonder what students will take from it. If I wasn't bound to use the term abstraction, I'd probably emphasize the benefit of reuse "When we realize we've developed a useful piece of functionality that we might want to use in other places, we can turn it into its own block." Anyway just musings from your local "abstraction" skeptic, feel free to delete. -- PF 8/20/21

I added your text at the beginning and am open to a Dan video and/or more discussion about teaching abstraction. :) --MF, 8/20/21

When you realize you've developed a useful piece of script behavior that you might want to use in other places, you can turn it into its own block. This is a form of abstraction.

Abstraction is an important idea in computer science. One kind of abstraction is breaking up a large problem into smaller sub-problems.

For example, instead of putting join (random animal) (s) into an input slot of super short story, you can create a plural of () block and put random animal in its input slot.

This makes your code easier to read, you can use this new block again in other places, and once the block is working, you don't need to think about how it works each time you use it. (For example, you might later improve plural to handle words such as "fly" and "box" that don't form their plural just by adding an "s.")

1.2.6

Hat blocks tell you when a piece of code should be run and what (if any) inputs it takes.
'plural of (word)' inside a hat-shaped block
This code will run whenever the plural block is called, and takes one input called word.

1.2.7: Local Variables
Revisit how to do this better for the middle school level. --MF, 7/23/23

Block inputs (such as job, action, number, and plural animal, in the super short story example) are called local variables because the value they report to join words varies based on what is typed into the input slots of super short story, but they only can be used in this local context (you can't drag them out of the block editor and expect them to work in other parts of your code).

Should this mention that block/script local is different from sprite local? -bh 2/6/22

Lab 4: Image Manipulation

1.4.1

A pixel (short for picture element) is the smallest programmable unit of color on a screen.

1.4.1

Resolution is the level of detail in an image.

1.4.2

A list is an ordered sequence of items.

PLEASE don't interrupt experiments with huge vocabulary lessons. The language "reports a list" is sufficient context to make clear what a list is. And anyway, kids already know. They've seen the lists you show here and before that they've seen shopping lists. The fact that a list, in this context is "an ordered sequence" (unlike a shopping list) is true and important but can be taken for granted. Kids want to experiment and the last two items in this activity are potentially fun and interesting. Making vocabulary a priority just guarantees that it will become the focus of the course, will be tested, and will kill any semblance of B and J that is left. --PG
consider hinting this to shorten the page. --MF, 7/24/23

You've seen a list before when you selected random items from lists in the Super Short Story project:
random job: {report (item (random) of (list (artist) (computer programmer) (cashier) (musician) (landscaper) (nurse) (plumber)))}
The output of random job was a random item from the list of jobs.

The output of RGB pixel is a list of three values: the amount of red, green, and blue for one pixel.

1.4.3: Sprites and Costumes

A sprite is an object that has scripts and a costume and can even move around on the stage.

Mary, this image still needs an update. --MF, 9/13/21

This project has two sprites: the Image sprite (in the center of the stage), and the PixelGrid sprite (in the top left). The Image sprite has the code you'll be playing with, and the PixelGrid sprite has the code that makes the grid of pixels.

Click for an image of the stage and the sprites.

image of Snap! stage with two sprites: the parrot photo and the grid of pixels. Below the stage is a row of several buttons (new sprite, edit sprite, new sprite from webcam, and delete sprite), and below that are two sprite buttons: 'Image', which has a small picture of the parrots; and 'PixelGrid', which shows no image.

A costume is picture that can be "worn" by a sprite.

Each sprite has a current costume and perhaps other possible costumes. The use costume block switches the Image sprite's current costume to the costume selected in the dropdown menu.
1.4.3: Table

A list is an ordered sequence of items, and a table is an ordered sequence of lists. So, a table is a list of lists. Each row in a table is another smaller list.

The output of the pixels of my costume block is a table with three columns. Each row is one pixel from the image (each with red, green, and blue values), so the three columns in the table are the amount of red, green, and blue in each pixel of the image.

Once day, a picture might be nice inside this hint. --MF, 9/13/21
Click for instructions for viewing a table as a list of lists.

Click the pixels of my costume block, and then right-click the table that appears and select "list view...". You will see the exact same data displayed as a list of lists. (You can right-click the over-arching list and select "table view..." to see the data as a table again.)

1.4.4: Abstraction

Hiding the details of how color from pixel selects the correct RGB value from a pixel (so you don't have to see the extra item of block) is a form of abstraction.

1.4.4: Higher-Order Function

Map is a higher-order function. That just means that it's a function that takes a function (in this case, color from pixel) as input.

This map expression
map (color ('red') from pixel 'list input slot') over (pixels of my costume))
takes two inputs:

  1. The function color from pixel: color (red) from pixel 'list input slot'
  2. The list that is the output of the function pixels of my costume (Click for a reminder of the output.)
    'pixels of my costume' reporting a table with 3 columns and 5 visible rows. (There is a row count of 15,552 in the upper left corner; not all rows are visible). The first column includes values ranging from 111-118; the second column includes values ranging from 111-117; the third column includes values ranging from 112-122.

You can tell the difference between the second input slot to map 'reporter input slot' over 'list input slot', which takes the output of a function (like most inputs do), and the first input slot, which takes a whole function itself (not its output), because the first input slot has a gray ring around it. The gray ring tells you that the map function is expecting a function (not the output of a function) as input.
gray ring

Map takes a function as input so it can apply that function to each item in the list. The empty input slot in the function (in this case, the pixel) is where each item from the list (in this case, the list of pixels) goes every time the function is applied.

Lab 5: Storing and Securing Data

1.5.1: Decimal Numerals

A decimal numeral is part of the base 10 system, the system we learn by counting on ten fingers.

In base 10, there are ten digits (0-9), and each place is worth ten times as much as the place to its right.

For example, consider the number 239...

2
3
9
100s place
10s place
1s place

The number 239 is equal to (2 × 100) + (3 × 10) + (9 × 1). You could write it in Snap! like this:
((2 × 100) + (3 × 10)) + (9 × 1) reporting 239
1.5.1: Binary Numerals

A binary numeral is part of the base 2 system.

In base 2, there are two digits (0-1), and each place is worth twice times as much as the place to its right.

For example, consider the binary numeral 1010...

1
0
1
0
8s place
4s place
2s place
1s place

We can figure out the decimal equivalent by adding up all the places that have a one (that is, 8 + 2 = 10). You could write it in Snap! like this:
(((1 × 8) + (0 × 4)) + (1 × 2)) + (0 × 1) reporting 1010
1.5.2: Bit

The word "bit" is an abbreviation for binary digit.

1.5.3: Hexadecimal Numerals
The letters A-F are used for the values 10-15:
10 11 12 13 14 15
A B C D E F

A hexadecimal numeral is part of the base 16 system.

In base 16, there are sixteen digits (0-9 and A-F), and each place is worth sixteen times as much as the place to its right.

For example, consider the hexadecimal numeral 2D9...

2
D
9
256s place
16s place
1s place

We can figure out the decimal equivalent by adding up the 2 two-hundred-fifty-sixes, the D (that is, 13) sixteens, and the 9 ones: (2 × 256) + (13 × 16) + (9 × 1) = 729. You could write it in Snap! like this:
(((2 × 256) + (13 × 16)) + (9 × 1) reporting 729
1.5.4

Lab 6: Texting Tricks

1.6.2: Predicate and Conditional

A predicate is a hexagon-shaped reporter that asks a true/false question such as these examples:
8 > 7 reporting true 6 > 7 reporting false

A conditional is a block that controls the code based on a true/false condition (the predicate). The if 'predicate input slot' then () else () block is an example of a conditional.

1.6.3

Like map, the find first block is a higher-order function because it takes a function (the predicate) as input.

Lab 7: Dealing with Data Dos

1.7.2

A variable is like a box that can store a value, such as a word, a number, or a list.

In Snap!, a table is a list of lists (a list with lists inside it).

1.7.2

A watcher is a window that lets you see what value is stored in a variable.

\ No newline at end of file diff --git a/sparks/student-pages/U2/unit-2-vocab.html b/sparks/student-pages/U2/unit-2-vocab.html new file mode 100644 index 0000000000..1a5c10d416 --- /dev/null +++ b/sparks/student-pages/U2/unit-2-vocab.html @@ -0,0 +1,18 @@ + + + + + + + + + + +Unit 2 Vocabulary + + + + +

Unit 2: Sequencing and Iteration

+

Lab 1: Song Player

+
2.1.1

A command block tells the computer to do something without reporting a value.

2.1.2

Repeating the same set of commands (such as with repeat or forever) is called looping or iteration.

2.1.3
You learned about reporters in Unit 1 Lab 1 Activity 4: Say Hello to Snap!.

A reporter block does a calculation and reports the result. Reporters have an oval shape.
item () of 'list input slot' join () () if 'predicate input slot' then () else ()

You learned about predicates in Unit 1 Lab 6 Activity 2: L33t Text.

A predicate is a special kind of reporter that asks a true/false question and reports either true or false. Predicates have a hexagon shape.
What does IS () A (LIST)? do? mouse down? () = ()

You'll use commands much more in Unit 2.

A command block tells the computer to do something without reporting a value. Commands have a puzzle shape and can be snapped together one after another.
set tempo to () bpm repeat () {} delete () from 'list input slot'

Unlike reporters, a command block doesn't report anything, so you can't use its result as the input to another block—its result is an action, not a value!
2.1.3: Abstraction

Hiding away the details of how code works (such as by moving it inside a new block) is a form of abstraction.

2.1.5

A list is an ordered sequence of items. You've been using lists throughout this course: to store words for a story, to manipulate the letters of a secret message, and even to store lists such as each individual's responses to the question in a survey.

What does "ordered" mean?

It doesn't mean that the items have to appear in alphabetical or numeric order. It just means that these are different lists:
(list a b) (list b a)

2.1.6: Global Variable

A global variable is a variable that is usable by all scripts in the program.

2.1.7

Recall, a function that takes a function as input (like map) is called a higher order function.

Lab 2: Graphics and Animation

2.2.1
2.2.1
2.2.9

An event is something that happens, such as clicking on a sprite, pressing a key, or clicking the green flag button (green-flag button) that tells the computer to do something.

2.2.13

A predicate is a hexagon-shaped reporter that asks a true/false question.

You learned about predicates in Unit 1 Lab 6 Activity 2: L33t Text.
\ No newline at end of file diff --git a/sparks/student-pages/U3/unit-3-vocab.html b/sparks/student-pages/U3/unit-3-vocab.html new file mode 100644 index 0000000000..07cb216438 --- /dev/null +++ b/sparks/student-pages/U3/unit-3-vocab.html @@ -0,0 +1,18 @@ + + + + + + + + + + +Unit 3 Vocabulary + + + + +

Unit 3: Hardware

+

Lab 1: Meet micro:bit

+
3.1.1

A software library is a collection of procedures (blocks) that can be used in programs.

Lab 2: Interactive Pet

3.2.1: Input and Output

In computing, the input is the action that tells the computer to do something. The output is the resulting action that occurs after the input command is received.

The micro:bit has different types of inputs: light (bright or dark), button pressed, or certain movement. The output we're currently exploring is displaying a picture on the LED display.

Lab 3: Game Play

3.3.1

A variable is like a labeled box that can store a value, such as a word, a number, or a list.

3.3.1

An analog input pin can read a voltage level that ranges of voltages provided to your micro:bit.

A switch is an electronic device that disconnects or connects and electrical path, resulting in a circuit turning off or on.

Lab 4: Marvelous Motions

3.4.1

A servo motor provides position control, so it can be told to move into an exact spot. Its position can be selected from 0 to 180 degrees.

Lab 5: Paper Stories

3.5.1

An LED contains a light emitter inside of a plastic bulb. This light emitter can be made from different materials, and when electricity runs through it, it shines different colors. However, electricity can only flow in one direction, and the name for electronic parts with this quality is called a diode. Thus, an LED stands for "light-emitting diode."

3.5.3

A parallel circuit has multiple branches and allows for easier addition of multiple LEDs. In parallel, the LEDs retain most of their brightness.

A series circuit has all elements in a chain, one after another and makes a complete circle. In series, the more LEDs added, the dimmer they become.

Lab 6: Making with Multiples

3.6.1: Radio Communication

Radio is a way of transmitting and receiving information over a distance.

\ No newline at end of file diff --git a/sparks/student-pages/review/index.html b/sparks/student-pages/review/index.html deleted file mode 100644 index 978c7ad452..0000000000 --- a/sparks/student-pages/review/index.html +++ /dev/null @@ -1,283 +0,0 @@ - - - - - - - - - - BJC Curriculum Index - - - - - - - -
-
- - - - - - - BJC Curriculum Index - - - - - - - -
-
- - diff --git a/sparks/student-pages/review/vocab1.html b/sparks/student-pages/review/vocab1.html deleted file mode 100644 index 610f9eb529..0000000000 --- a/sparks/student-pages/review/vocab1.html +++ /dev/null @@ -1,18 +0,0 @@ - - - - - - Unit 1 Vocabulary - - - - - - - -

Unit 1 Lab 1: Introduction to Snap!, Activity 1

-

Lab 1: Introduction to Snap!

-
1.1.1
1.1.1

A block is a piece of code. If you click a block, the computer will run the code.

Lab 2: Super Short Stories

1.2.2: Abstraction

Will they be watching a video on abstraction here? Or does Dan mention it in welcome? It feels so..abstract..here that I wonder what students will take from it. If I wasn't bound to use the term abstraction, I'd probably emphasize the benefit of reuse "When we realize we've developed a useful piece of functionality that we might want to use in other places, we can turn it into its own block." Anyway just musings from your local "abstraction" skeptic, feel free to delete. -- PF 8/20/21

I added your text at the beginning and am open to a Dan video and/or more discussion about teaching abstraction. :) --MF, 8/20/21

When you realize you've developed a useful piece of script behavior that you might want to use in other places, you can turn it into its own block. This is a form of abstraction.

Abstraction is an important idea in computer science. One kind of abstraction is breaking up a large problem into smaller sub-problems.

For example, instead of putting join (random animal) (s) into an input slot of super short story, you can create a plural of () block and put random animal in its input slot.

This makes your code easier to read, you can use this new block again in other places, and once the block is working, you don't need to think about how it works each time you use it. (For example, you might later improve plural to handle words such as "fly" and "box" that don't form their plural just by adding an "s.")

1.2.2

Hat blocks tell you when a piece of code should be run and what (if any) inputs it takes.
'plural of (word)' inside a hat-shaped block
This code will run whenever the plural block is called, and takes one input called word.

1.2.3: Local Variables

Block inputs (such as feeling, job, action 1, place, action 2, etc., in the super short story example) are called local variables because the value they report to join words varies based on what is typed into the input slots of super short story, but they only can be used in this local context (you can't drag them out of the block editor and expect them to work in other parts of your code).

Should this mention that block/script local is different from sprite local? -bh 2/6/22

Lab 4: Image Manipulation

1.4.1

A pixel (short for picture element) is the smallest programmable unit of color on a screen.

1.4.1

Resolution is the level of detail in an image.

1.4.2

A list is an ordered sequence of items.

PLEASE don't interrupt experiments with huge vocabulary lessons. The language "reports a list" is sufficient context to make clear what a list is. And anyway, kids already know. They've seen the lists you show here and before that they've seen shopping lists. The fact that a list, in this context is "an ordered sequence" (unlike a shopping list) is true and important but can be taken for granted. Kids want to experiment and the last two items in this activity are potentially fun and interesting. Making vocabulary a priority just guarantees that it will become the focus of the course, will be tested, and will kill any semblance of B and J that is left. --PG

You've seen a list before when you selected random items from lists in the Super Short Story project:
random job: {report (item (random) of (list (artist) (computer programmer) (cashier) (musician) (landscaper) (nurse) (plumber)))}
The output of random job was a random item from the list of jobs.

The output of RGB pixel is a list of three values: the amount of red, green, and blue for one pixel.

1.4.3: Sprites and Costumes

A sprite is an object that has scripts and a costume and can even move around on the stage.

Mary, this image still needs an update. --MF, 9/13/21

This project has two sprites: the Image sprite (in the center of the stage), and the PixelGrid sprite (in the top left). The Image sprite has the code you'll be playing with, and the PixelGrid sprite has the code that makes the grid of pixels.

Click for an image of the stage and the sprites.

image of Snap! stage with two sprites: the parrot photo and the grid of pixels. Below the stage is a row of several buttons (new sprite, edit sprite, new sprite from webcam, and delete sprite), and below that are two sprite buttons: 'Image', which has a small picture of the parrots; and 'PixelGrid', which shows no image.

A costume is picture that can be "worn" by a sprite.

Each sprite has a current costume and perhaps other possible costumes. The use costume block switches the Image sprite's current costume to the costume selected in the dropdown menu.
1.4.3: Table

A list is an ordered sequence of items, and a table is an ordered sequence of lists. So, a table is a list of lists. Each row in a table is another smaller list.

The output of the pixels of my costume block is a table with three columns. Each row is one pixel from the image (each with red, green, and blue values), so the three columns in the table are the amount of red, green, and blue in each pixel of the image.

Once day, a picture might be nice inside this hint. --MF, 9/13/21
Click for instructions for viewing a table as a list of lists.

Click the pixels of my costume block, and then right-click the table that appears and select "list view...". You will see the exact same data displayed as a list of lists. (You can right-click the over-arching list and select "table view..." to see the data as a table again.)

1.4.4: Abstraction

Hiding the details of how color from pixel selects the correct RGB value from a pixel (so you don't have to see the extra item of block) is a form of abstraction.

1.4.4: Higher-Order Function

Map is a higher-order function. That just means that it's a function that takes a function (in this case, color from pixel) as input.

This map expression
map (color ('red') from pixel 'list input slot') over (pixels of my costume))
takes two inputs:

  1. The function color from pixel: color (red) from pixel 'list input slot'
  2. The list that is the output of the function pixels of my costume (Click for a reminder of the output.)
    'pixels of my costume' reporting a table with 3 columns and 5 visible rows. (There is a row count of 15,552 in the upper left corner; not all rows are visible). The first column includes values ranging from 111-118; the second column includes values ranging from 111-117; the third column includes values ranging from 112-122.

You can tell the difference between the second input slot to map 'reporter input slot' over 'list input slot', which takes the output of a function (like most inputs do), and the first input slot, which takes a whole function itself (not its output), because the first input slot has a gray ring around it. The gray ring tells you that the map function is expecting a function (not the output of a function) as input.
gray ring

Map takes a function as input so it can apply that function to each item in the list. The empty input slot in the function (in this case, the pixel) is where each item from the list (in this case, the list of pixels) goes every time the function is applied.

Lab 5: Storing and Securing Data

1.5.1: Decimal Numerals

A decimal numeral is part of the base 10 system, the system we learn by counting on ten fingers.

In base 10, there are ten digits (0-9), and each place is worth ten times as much as the place to its right.

For example, consider the number 239...

2
3
9
100s place
10s place
1s place

The number 239 is equal to (2 × 100) + (3 × 10) + (9 × 1). You could write it in Snap! like this:
((2 × 100) + (3 × 10)) + (9 × 1) reporting 239
1.5.1: Binary Numerals

A binary numeral is part of the base 2 system.

In base 2, there are two digits (0-1), and each place is worth twice times as much as the place to its right.

For example, consider the binary numeral 1010...

1
0
1
0
8s place
4s place
2s place
1s place

We can figure out the decimal equivalent by adding up all the places that have a one (that is, 8 + 2 = 10). You could write it in Snap! like this:
(((1 × 8) + (0 × 4)) + (1 × 2)) + (0 × 1) reporting 1010
1.5.2: Bit

The word "bit" is an abbreviation for binary digit.

1.5.3: Hexadecimal Numerals
The letters A-F are used for the values 10-15:
10 11 12 13 14 15
A B C D E F

A hexadecimal numeral is part of the base 16 system.

In base 16, there are sixteen digits (0-9 and A-F), and each place is worth sixteen times as much as the place to its right.

For example, consider the hexadecimal numeral 2D9...

2
D
9
256s place
16s place
1s place

We can figure out the decimal equivalent by adding up the 2 two-hundred-fifty-sixes, the D (that is, 13) sixteens, and the 9 ones: (2 × 256) + (13 × 16) + (9 × 1) = 729. You could write it in Snap! like this:
(((2 × 256) + (13 × 16)) + (9 × 1) reporting 729
1.5.4

Lab 6: Texting Tricks

1.6.2: Predicate and Conditional

A predicate is a hexagon-shaped reporter that asks a true/false question such as these examples:
8 > 7 reporting true 6 > 7 reporting false

A conditional is a block that controls the code based on a true/false condition (the predicate). The if 'predicate input slot' then () else () block is an example of a conditional.

1.6.3

Like map, the find first block is a higher-order function because it takes a function (the predicate) as input.

Lab 7: Dealing with Data Dos

1.7.2

A variable is like a box that can store a value, such as a word, a number, or a list.

In Snap!, a table is a list of lists (a list with lists inside it).

1.7.2

A watcher is a window that lets you see what value is stored in a variable.

-

Lab 1: Introduction to Snap!

1.1.1
1.1.1

A block is a piece of code. If you click a block, the computer will run the code.

Lab 2: Super Short Stories

1.2.2: Abstraction

Will they be watching a video on abstraction here? Or does Dan mention it in welcome? It feels so..abstract..here that I wonder what students will take from it. If I wasn't bound to use the term abstraction, I'd probably emphasize the benefit of reuse "When we realize we've developed a useful piece of functionality that we might want to use in other places, we can turn it into its own block." Anyway just musings from your local "abstraction" skeptic, feel free to delete. -- PF 8/20/21

I added your text at the beginning and am open to a Dan video and/or more discussion about teaching abstraction. :) --MF, 8/20/21

When you realize you've developed a useful piece of script behavior that you might want to use in other places, you can turn it into its own block. This is a form of abstraction.

Abstraction is an important idea in computer science. One kind of abstraction is breaking up a large problem into smaller sub-problems.

For example, instead of putting join (random animal) (s) into an input slot of super short story, you can create a plural of () block and put random animal in its input slot.

This makes your code easier to read, you can use this new block again in other places, and once the block is working, you don't need to think about how it works each time you use it. (For example, you might later improve plural to handle words such as "fly" and "box" that don't form their plural just by adding an "s.")

1.2.2

Hat blocks tell you when a piece of code should be run and what (if any) inputs it takes.
'plural of (word)' inside a hat-shaped block
This code will run whenever the plural block is called, and takes one input called word.

1.2.3: Local Variables

Block inputs (such as feeling, job, action 1, place, action 2, etc., in the super short story example) are called local variables because the value they report to join words varies based on what is typed into the input slots of super short story, but they only can be used in this local context (you can't drag them out of the block editor and expect them to work in other parts of your code).

Should this mention that block/script local is different from sprite local? -bh 2/6/22

Lab 4: Image Manipulation

1.4.1

A pixel (short for picture element) is the smallest programmable unit of color on a screen.

1.4.1

Resolution is the level of detail in an image.

1.4.2

A list is an ordered sequence of items.

PLEASE don't interrupt experiments with huge vocabulary lessons. The language "reports a list" is sufficient context to make clear what a list is. And anyway, kids already know. They've seen the lists you show here and before that they've seen shopping lists. The fact that a list, in this context is "an ordered sequence" (unlike a shopping list) is true and important but can be taken for granted. Kids want to experiment and the last two items in this activity are potentially fun and interesting. Making vocabulary a priority just guarantees that it will become the focus of the course, will be tested, and will kill any semblance of B and J that is left. --PG

You've seen a list before when you selected random items from lists in the Super Short Story project:
random job: {report (item (random) of (list (artist) (computer programmer) (cashier) (musician) (landscaper) (nurse) (plumber)))}
The output of random job was a random item from the list of jobs.

The output of RGB pixel is a list of three values: the amount of red, green, and blue for one pixel.

1.4.3: Sprites and Costumes

A sprite is an object that has scripts and a costume and can even move around on the stage.

Mary, this image still needs an update. --MF, 9/13/21

This project has two sprites: the Image sprite (in the center of the stage), and the PixelGrid sprite (in the top left). The Image sprite has the code you'll be playing with, and the PixelGrid sprite has the code that makes the grid of pixels.

Click for an image of the stage and the sprites.

image of Snap! stage with two sprites: the parrot photo and the grid of pixels. Below the stage is a row of several buttons (new sprite, edit sprite, new sprite from webcam, and delete sprite), and below that are two sprite buttons: 'Image', which has a small picture of the parrots; and 'PixelGrid', which shows no image.

A costume is picture that can be "worn" by a sprite.

Each sprite has a current costume and perhaps other possible costumes. The use costume block switches the Image sprite's current costume to the costume selected in the dropdown menu.
1.4.3: Table

A list is an ordered sequence of items, and a table is an ordered sequence of lists. So, a table is a list of lists. Each row in a table is another smaller list.

The output of the pixels of my costume block is a table with three columns. Each row is one pixel from the image (each with red, green, and blue values), so the three columns in the table are the amount of red, green, and blue in each pixel of the image.

Once day, a picture might be nice inside this hint. --MF, 9/13/21
Click for instructions for viewing a table as a list of lists.

Click the pixels of my costume block, and then right-click the table that appears and select "list view...". You will see the exact same data displayed as a list of lists. (You can right-click the over-arching list and select "table view..." to see the data as a table again.)

1.4.4: Abstraction

Hiding the details of how color from pixel selects the correct RGB value from a pixel (so you don't have to see the extra item of block) is a form of abstraction.

1.4.4: Higher-Order Function

Map is a higher-order function. That just means that it's a function that takes a function (in this case, color from pixel) as input.

This map expression
map (color ('red') from pixel 'list input slot') over (pixels of my costume))
takes two inputs:

  1. The function color from pixel: color (red) from pixel 'list input slot'
  2. The list that is the output of the function pixels of my costume (Click for a reminder of the output.)
    'pixels of my costume' reporting a table with 3 columns and 5 visible rows. (There is a row count of 15,552 in the upper left corner; not all rows are visible). The first column includes values ranging from 111-118; the second column includes values ranging from 111-117; the third column includes values ranging from 112-122.

You can tell the difference between the second input slot to map 'reporter input slot' over 'list input slot', which takes the output of a function (like most inputs do), and the first input slot, which takes a whole function itself (not its output), because the first input slot has a gray ring around it. The gray ring tells you that the map function is expecting a function (not the output of a function) as input.
gray ring

Map takes a function as input so it can apply that function to each item in the list. The empty input slot in the function (in this case, the pixel) is where each item from the list (in this case, the list of pixels) goes every time the function is applied.

Lab 5: Storing and Securing Data

1.5.1: Decimal Numerals

A decimal numeral is part of the base 10 system, the system we learn by counting on ten fingers.

In base 10, there are ten digits (0-9), and each place is worth ten times as much as the place to its right.

For example, consider the number 239...

2
3
9
100s place
10s place
1s place

The number 239 is equal to (2 × 100) + (3 × 10) + (9 × 1). You could write it in Snap! like this:
((2 × 100) + (3 × 10)) + (9 × 1) reporting 239
1.5.1: Binary Numerals

A binary numeral is part of the base 2 system.

In base 2, there are two digits (0-1), and each place is worth twice times as much as the place to its right.

For example, consider the binary numeral 1010...

1
0
1
0
8s place
4s place
2s place
1s place

We can figure out the decimal equivalent by adding up all the places that have a one (that is, 8 + 2 = 10). You could write it in Snap! like this:
(((1 × 8) + (0 × 4)) + (1 × 2)) + (0 × 1) reporting 1010
1.5.2: Bit

The word "bit" is an abbreviation for binary digit.

1.5.3: Hexadecimal Numerals
The letters A-F are used for the values 10-15:
10 11 12 13 14 15
A B C D E F

A hexadecimal numeral is part of the base 16 system.

In base 16, there are sixteen digits (0-9 and A-F), and each place is worth sixteen times as much as the place to its right.

For example, consider the hexadecimal numeral 2D9...

2
D
9
256s place
16s place
1s place

We can figure out the decimal equivalent by adding up the 2 two-hundred-fifty-sixes, the D (that is, 13) sixteens, and the 9 ones: (2 × 256) + (13 × 16) + (9 × 1) = 729. You could write it in Snap! like this:
(((2 × 256) + (13 × 16)) + (9 × 1) reporting 729
1.5.4

Lab 6: Texting Tricks

1.6.2: Predicate and Conditional

A predicate is a hexagon-shaped reporter that asks a true/false question such as these examples:
8 > 7 reporting true 6 > 7 reporting false

A conditional is a block that controls the code based on a true/false condition (the predicate). The if 'predicate input slot' then () else () block is an example of a conditional.

1.6.3

Like map, the find first block is a higher-order function because it takes a function (the predicate) as input.

Lab 7: Dealing with Data Dos

1.7.2

A variable is like a box that can store a value, such as a word, a number, or a list.

In Snap!, a table is a list of lists (a list with lists inside it).

1.7.2

A watcher is a window that lets you see what value is stored in a variable.

- diff --git a/sparks/student-pages/review/vocab2.html b/sparks/student-pages/review/vocab2.html deleted file mode 100644 index 2ee46b23a5..0000000000 --- a/sparks/student-pages/review/vocab2.html +++ /dev/null @@ -1,19 +0,0 @@ - - - - - - Unit 2 Vocabulary - - - - -

Unit 2 Lab 1: Song Player, Activity 1

-

Lab 1: Song Player

-
2.1.1

A command block tells the computer to do something without reporting a value.

2.1.2

Repeating the same set of commands (such as with repeat or forever) is called looping or iteration.

2.1.3
You learned about reporters in Unit 1 Lab 1 Activity 4: Say Hello to Snap!.

A reporter block does a calculation and reports the result. Reporters have an oval shape.
item () of 'list input slot' join () () if 'predicate input slot' then () else ()

You learned about predicates in Unit 1 Lab 6 Activity 2: L33t Text.

A predicate is a special kind of reporter that asks a true/false question and reports either true or false. Predicates have a hexagon shape.
What does IS () A (LIST)? do? mouse down? () = ()

You'll use commands much more in Unit 2.

A command block tells the computer to do something without reporting a value. Commands have a puzzle shape and can be snapped together one after another.
set tempo to () bpm repeat () {} delete () from 'list input slot'

Unlike reporters, a command block doesn't report anything, so you can't use its result as the input to another block—its result is an action, not a value!
2.1.3: Abstraction

Hiding away the details of how code works (such as by moving it inside a new block) is a form of abstraction.

2.1.5

A list is an ordered sequence of items. You've been using lists throughout this course: to store words for a story, to manipulate the letters of a secret message, and even to store lists such as each individual's responses to the question in a survey.

What does "ordered" mean?

It doesn't mean that the items have to appear in alphabetical or numeric order. It just means that these are different lists:
(list a b) (list b a)

2.1.6: Global Variable

A global variable is a variable that is usable by all scripts in the program.

2.1.7

Recall, a function that takes a function as input (like map) is called a higher order function.

-

Lab 1: Song Player

2.1.1

A command block tells the computer to do something without reporting a value.

2.1.2

Repeating the same set of commands (such as with repeat or forever) is called looping or iteration.

2.1.3
You learned about reporters in Unit 1 Lab 1 Activity 4: Say Hello to Snap!.

A reporter block does a calculation and reports the result. Reporters have an oval shape.
item () of 'list input slot' join () () if 'predicate input slot' then () else ()

You learned about predicates in Unit 1 Lab 6 Activity 2: L33t Text.

A predicate is a special kind of reporter that asks a true/false question and reports either true or false. Predicates have a hexagon shape.
What does IS () A (LIST)? do? mouse down? () = ()

You'll use commands much more in Unit 2.

A command block tells the computer to do something without reporting a value. Commands have a puzzle shape and can be snapped together one after another.
set tempo to () bpm repeat () {} delete () from 'list input slot'

Unlike reporters, a command block doesn't report anything, so you can't use its result as the input to another block—its result is an action, not a value!
2.1.3: Abstraction

Hiding away the details of how code works (such as by moving it inside a new block) is a form of abstraction.

2.1.5

A list is an ordered sequence of items. You've been using lists throughout this course: to store words for a story, to manipulate the letters of a secret message, and even to store lists such as each individual's responses to the question in a survey.

What does "ordered" mean?

It doesn't mean that the items have to appear in alphabetical or numeric order. It just means that these are different lists:
(list a b) (list b a)

2.1.6: Global Variable

A global variable is a variable that is usable by all scripts in the program.

2.1.7

Recall, a function that takes a function as input (like map) is called a higher order function.

-

Lab 2: Graphics and Animation

2.2.1
2.2.1
2.2.9

An event is something that happens, such as clicking on a sprite, pressing a key, or clicking the green flag button (green-flag button) that tells the computer to do something.

2.2.13

A predicate is a hexagon-shaped reporter that asks a true/false question.

You learned about predicates in Unit 1 Lab 6 Activity 2: L33t Text.
-

Lab 1: Song Player

2.1.1

A command block tells the computer to do something without reporting a value.

2.1.2

Repeating the same set of commands (such as with repeat or forever) is called looping or iteration.

2.1.3
You learned about reporters in Unit 1 Lab 1 Activity 4: Say Hello to Snap!.

A reporter block does a calculation and reports the result. Reporters have an oval shape.
item () of 'list input slot' join () () if 'predicate input slot' then () else ()

You learned about predicates in Unit 1 Lab 6 Activity 2: L33t Text.

A predicate is a special kind of reporter that asks a true/false question and reports either true or false. Predicates have a hexagon shape.
What does IS () A (LIST)? do? mouse down? () = ()

You'll use commands much more in Unit 2.

A command block tells the computer to do something without reporting a value. Commands have a puzzle shape and can be snapped together one after another.
set tempo to () bpm repeat () {} delete () from 'list input slot'

Unlike reporters, a command block doesn't report anything, so you can't use its result as the input to another block—its result is an action, not a value!
2.1.3: Abstraction

Hiding away the details of how code works (such as by moving it inside a new block) is a form of abstraction.

2.1.5

A list is an ordered sequence of items. You've been using lists throughout this course: to store words for a story, to manipulate the letters of a secret message, and even to store lists such as each individual's responses to the question in a survey.

What does "ordered" mean?

It doesn't mean that the items have to appear in alphabetical or numeric order. It just means that these are different lists:
(list a b) (list b a)

2.1.6: Global Variable

A global variable is a variable that is usable by all scripts in the program.

2.1.7

Recall, a function that takes a function as input (like map) is called a higher order function.

-

Lab 1: Song Player

2.1.1

A command block tells the computer to do something without reporting a value.

2.1.2

Repeating the same set of commands (such as with repeat or forever) is called looping or iteration.

2.1.3
You learned about reporters in Unit 1 Lab 1 Activity 4: Say Hello to Snap!.

A reporter block does a calculation and reports the result. Reporters have an oval shape.
item () of 'list input slot' join () () if 'predicate input slot' then () else ()

You learned about predicates in Unit 1 Lab 6 Activity 2: L33t Text.

A predicate is a special kind of reporter that asks a true/false question and reports either true or false. Predicates have a hexagon shape.
What does IS () A (LIST)? do? mouse down? () = ()

You'll use commands much more in Unit 2.

A command block tells the computer to do something without reporting a value. Commands have a puzzle shape and can be snapped together one after another.
set tempo to () bpm repeat () {} delete () from 'list input slot'

Unlike reporters, a command block doesn't report anything, so you can't use its result as the input to another block—its result is an action, not a value!
2.1.3: Abstraction

Hiding away the details of how code works (such as by moving it inside a new block) is a form of abstraction.

2.1.5

A list is an ordered sequence of items. You've been using lists throughout this course: to store words for a story, to manipulate the letters of a secret message, and even to store lists such as each individual's responses to the question in a survey.

What does "ordered" mean?

It doesn't mean that the items have to appear in alphabetical or numeric order. It just means that these are different lists:
(list a b) (list b a)

2.1.6: Global Variable

A global variable is a variable that is usable by all scripts in the program.

2.1.7

Recall, a function that takes a function as input (like map) is called a higher order function.

-

Lab 2: Graphics and Animation

2.2.1
2.2.1
2.2.9

An event is something that happens, such as clicking on a sprite, pressing a key, or clicking the green flag button (green-flag button) that tells the computer to do something.

2.2.13

A predicate is a hexagon-shaped reporter that asks a true/false question.

You learned about predicates in Unit 1 Lab 6 Activity 2: L33t Text.
- diff --git a/sparks/student-pages/review/vocab3.html b/sparks/student-pages/review/vocab3.html deleted file mode 100644 index 5f418d11f8..0000000000 --- a/sparks/student-pages/review/vocab3.html +++ /dev/null @@ -1,15 +0,0 @@ - - - - - - Unit 3 Vocabulary - - - - -

Unit 3 Lab 1: Meet micro:bit, Activity 1

-

Lab 1: Meet micro:bit

-
3.1.1

A software library is a collection of procedures (blocks) that can be used in programs.

Lab 2: Interactive Pet

3.2.1: Input and Output

In computing, the input is the action that tells the computer to do something. The output is the resulting action that occurs after the input command is received.

The micro:bit has different types of inputs: light (bright or dark), button pressed, or certain movement. The output we're currently exploring is displaying a picture on the LED display.

Lab 3: Game Play

3.3.1

A variable is like a labeled box that can store a value, such as a word, a number, or a list.

3.3.1

An analog input pin can read a voltage level that ranges of voltages provided to your micro:bit.

A switch is an electronic device that disconnects or connects and electrical path, resulting in a circuit turning off or on.

Lab 4: Marvelous Motions

3.4.1

A servo motor provides position control, so it can be told to move into an exact spot. Its position can be selected from 0 to 180 degrees.

Lab 5: Paper Stories

3.5.1

An LED contains a light emitter inside of a plastic bulb. This light emitter can be made from different materials, and when electricity runs through it, it shines different colors. However, electricity can only flow in one direction, and the name for electronic parts with this quality is called a diode. Thus, an LED stands for "light-emitting diode."

3.5.3

A parallel circuit has multiple branches and allows for easier addition of multiple LEDs. In parallel, the LEDs retain most of their brightness.

A series circuit has all elements in a chain, one after another and makes a complete circle. In series, the more LEDs added, the dimmer they become.

Lab 6: Making with Multiples

3.6.1: Radio Communication

Radio is a way of transmitting and receiving information over a distance.

-

Lab 1: Meet micro:bit

3.1.1

A software library is a collection of procedures (blocks) that can be used in programs.

Lab 2: Interactive Pet

3.2.1: Input and Output

In computing, the input is the action that tells the computer to do something. The output is the resulting action that occurs after the input command is received.

The micro:bit has different types of inputs: light (bright or dark), button pressed, or certain movement. The output we're currently exploring is displaying a picture on the LED display.

Lab 3: Game Play

3.3.1

A variable is like a labeled box that can store a value, such as a word, a number, or a list.

3.3.1

An analog input pin can read a voltage level that ranges of voltages provided to your micro:bit.

A switch is an electronic device that disconnects or connects and electrical path, resulting in a circuit turning off or on.

Lab 4: Marvelous Motions

3.4.1

A servo motor provides position control, so it can be told to move into an exact spot. Its position can be selected from 0 to 180 degrees.

Lab 5: Paper Stories

3.5.1

An LED contains a light emitter inside of a plastic bulb. This light emitter can be made from different materials, and when electricity runs through it, it shines different colors. However, electricity can only flow in one direction, and the name for electronic parts with this quality is called a diode. Thus, an LED stands for "light-emitting diode."

3.5.3

A parallel circuit has multiple branches and allows for easier addition of multiple LEDs. In parallel, the LEDs retain most of their brightness.

A series circuit has all elements in a chain, one after another and makes a complete circle. In series, the more LEDs added, the dimmer they become.

Lab 6: Making with Multiples

3.6.1: Radio Communication

Radio is a way of transmitting and receiving information over a distance.

- diff --git a/sparks/student-pages/vocab-index.html b/sparks/student-pages/vocab-index.html new file mode 100644 index 0000000000..b0dbddcab8 --- /dev/null +++ b/sparks/student-pages/vocab-index.html @@ -0,0 +1,147 @@ + + + + + + + + + + + BJC Curriculum Index + + + + + + + + +
+
+ + \ No newline at end of file diff --git a/topic/nyc_bjc/1-intro-loops.es.topic b/topic/nyc_bjc/1-intro-loops.es.topic index 8f210b88c7..94d9ab3caa 100755 --- a/topic/nyc_bjc/1-intro-loops.es.topic +++ b/topic/nyc_bjc/1-intro-loops.es.topic @@ -49,3 +49,8 @@ heading: Proyectos opcionales resource: Diseño margarita [/bjc-r/cur/programming/1-introduction/optional-projects/4-daisy.es.html] resource: Modelar el lenguaje [/bjc-r/cur/programming/1-introduction/optional-projects/5-sentence-builder.es.html] } +heading: (NEW) Unidad 1 Revision + resource: (NEW) Vocabulario [/bjc-r/cur/programming/1-introduction/unit-1-vocab.es.html] + resource: (NEW) En el examen AP [/bjc-r/cur/programming/1-introduction/unit-1-exam-reference.es.html] + resource: (NEW) Preguntas de autocomprobacion [/bjc-r/cur/programming/1-introduction/unit-1-self-check.es.html] +} \ No newline at end of file diff --git a/topic/nyc_bjc/1-intro-loops.topic b/topic/nyc_bjc/1-intro-loops.topic index 372557a5a0..016b973dc4 100755 --- a/topic/nyc_bjc/1-intro-loops.topic +++ b/topic/nyc_bjc/1-intro-loops.topic @@ -45,10 +45,8 @@ heading: Optional Projects resource: The Game of Pong [/bjc-r/cur/programming/1-introduction/optional-projects/3-pong.html] resource: Daisy Design [/bjc-r/cur/programming/1-introduction/optional-projects/4-daisy.html] resource: Modeling Language [/bjc-r/cur/programming/1-introduction/optional-projects/5-sentence-builder.html] - - -heading: Unit 1 Review - resource: Vocabulary [/bjc-r/cur/programming/summaries/vocab1.html] - resource: On the AP Exam [/bjc-r/cur/programming/summaries/exam1.html] - resource: Self-Check Questions [/bjc-r/cur/programming/summaries/assessment-data1.html] -} +heading: (NEW) Unit 1 Review + resource: (NEW) Vocabulary [/bjc-r/cur/programming/1-introduction/unit-1-vocab.html] + resource: (NEW) On the AP Exam [/bjc-r/cur/programming/1-introduction/unit-1-exam-reference.html] + resource: (NEW) Self-Check Questions [/bjc-r/cur/programming/1-introduction/unit-1-self-check.html] +} \ No newline at end of file diff --git a/topic/nyc_bjc/2-conditionals-abstraction.es.topic b/topic/nyc_bjc/2-conditionals-abstraction.es.topic index 481ee4897e..6ec7ea776e 100755 --- a/topic/nyc_bjc/2-conditionals-abstraction.es.topic +++ b/topic/nyc_bjc/2-conditionals-abstraction.es.topic @@ -50,3 +50,8 @@ heading: Proyectos opcionales //resource: Tic-Tac-Toe Using Sprites [/bjc-r/cur/programming/2-complexity/optional-projects/4-tic-tac-toe.es.html] } +heading: (NEW) Unidad 2 Revision + resource: (NEW) Vocabulario [/bjc-r/cur/programming/2-complexity/unit-2-vocab.es.html] + resource: (NEW) En el examen AP [/bjc-r/cur/programming/2-complexity/unit-2-exam-reference.es.html] + resource: (NEW) Preguntas de autocomprobacion [/bjc-r/cur/programming/2-complexity/unit-2-self-check.es.html] +} \ No newline at end of file diff --git a/topic/nyc_bjc/2-conditionals-abstraction.topic b/topic/nyc_bjc/2-conditionals-abstraction.topic index 531ed01b57..82723be53a 100755 --- a/topic/nyc_bjc/2-conditionals-abstraction.topic +++ b/topic/nyc_bjc/2-conditionals-abstraction.topic @@ -51,10 +51,8 @@ heading: Optional Projects //resource: Abstract Data Types [/bjc-r/cur/programming/2-complexity/optional-projects/future/2-data-types.html] //resource: Capturing Clicks to Draw [/bjc-r/cur/programming/2-complexity/optional-projects/future/3-click-points.html] //resource: Diagonal Design [/bjc-r/cur/programming/2-complexity/optional-projects/future/7-diagonal-design.html] - - -heading: Unit 2 Review - resource: Vocabulary [/bjc-r/cur/programming/summaries/vocab2.html] - resource: On the AP Exam [/bjc-r/cur/programming/summaries/exam2.html] - resource: Self-Check Questions [/bjc-r/cur/programming/summaries/assessment-data2.html] -} +heading: (NEW) Unit 2 Review + resource: (NEW) Vocabulary [/bjc-r/cur/programming/2-complexity/unit-2-vocab.html] + resource: (NEW) On the AP Exam [/bjc-r/cur/programming/2-complexity/unit-2-exam-reference.html] + resource: (NEW) Self-Check Questions [/bjc-r/cur/programming/2-complexity/unit-2-self-check.html] +} \ No newline at end of file diff --git a/topic/nyc_bjc/3-lists.es.topic b/topic/nyc_bjc/3-lists.es.topic index cd0fd8bba1..fc111576d9 100644 --- a/topic/nyc_bjc/3-lists.es.topic +++ b/topic/nyc_bjc/3-lists.es.topic @@ -44,3 +44,8 @@ heading: Proyectos opcionales resource: Proyecto musical [/bjc-r/cur/programming/3-lists/optional-projects/4-music-project.es.html] } +heading: (NEW) Unidad 3 Revision + resource: (NEW) Vocabulario [/bjc-r/cur/programming/3-lists/unit-3-vocab.es.html] + resource: (NEW) En el examen AP [/bjc-r/cur/programming/3-lists/unit-3-exam-reference.es.html] + resource: (NEW) Preguntas de autocomprobacion [/bjc-r/cur/programming/3-lists/unit-3-self-check.es.html] +} \ No newline at end of file diff --git a/topic/nyc_bjc/3-lists.topic b/topic/nyc_bjc/3-lists.topic index 785d3d0ee4..aefe3d3e77 100644 --- a/topic/nyc_bjc/3-lists.topic +++ b/topic/nyc_bjc/3-lists.topic @@ -42,10 +42,8 @@ heading: Optional Projects resource: Animation Studio [/bjc-r/cur/programming/3-lists/optional-projects/2-animation-studio.html] resource: Op Art [/bjc-r/cur/programming/3-lists/optional-projects/3-op-art.html] resource: Music Project [/bjc-r/cur/programming/3-lists/optional-projects/4-music-project.html] - - -heading: Unit 3 Review - resource: Vocabulary [/bjc-r/cur/programming/summaries/vocab3.html] - resource: On the AP Exam [/bjc-r/cur/programming/summaries/exam3.html] - resource: Self-Check Questions [/bjc-r/cur/programming/summaries/assessment-data3.html] -} +heading: (NEW) Unit 3 Review + resource: (NEW) Vocabulary [/bjc-r/cur/programming/3-lists/unit-3-vocab.html] + resource: (NEW) On the AP Exam [/bjc-r/cur/programming/3-lists/unit-3-exam-reference.html] + resource: (NEW) Self-Check Questions [/bjc-r/cur/programming/3-lists/unit-3-self-check.html] +} \ No newline at end of file diff --git a/topic/nyc_bjc/4-internet.es.topic b/topic/nyc_bjc/4-internet.es.topic index f4fb5b6427..b7eb3ca22b 100644 --- a/topic/nyc_bjc/4-internet.es.topic +++ b/topic/nyc_bjc/4-internet.es.topic @@ -58,3 +58,7 @@ heading: Laboratorio 4: Representación y compresión de datos //resource: Weather App Project (Teacher's Choice) [/bjc-r/cur/programming/6-computers/optional-projects/weather-app.es.html] } +heading: (NEW) Unidad 4 Revision + resource: (NEW) Vocabulario [/bjc-r/cur/programming/4-internet/unit-4-vocab.es.html] + resource: (NEW) Preguntas de autocomprobacion [/bjc-r/cur/programming/4-internet/unit-4-self-check.es.html] +} \ No newline at end of file diff --git a/topic/nyc_bjc/4-internet.topic b/topic/nyc_bjc/4-internet.topic index ca1304dca7..6a7f716570 100644 --- a/topic/nyc_bjc/4-internet.topic +++ b/topic/nyc_bjc/4-internet.topic @@ -50,8 +50,7 @@ heading: Lab 4: Data Representation and Compression //heading: Optional Projects //resource: HTML Website [/bjc-r/cur/programming/4-internet/optional-projects/writing-html.html] //resource: Weather App Project (Teacher's Choice) [/bjc-r/cur/programming/6-computers/optional-projects/weather-app.html] - -heading: Unit 4 Review - resource: Vocabulary [/bjc-r/cur/programming/summaries/vocab4.html] - resource: Self-Check Questions [/bjc-r/cur/programming/summaries/assessment-data4.html] -} +heading: (NEW) Unit 4 Review + resource: (NEW) Vocabulary [/bjc-r/cur/programming/4-internet/unit-4-vocab.html] + resource: (NEW) Self-Check Questions [/bjc-r/cur/programming/4-internet/unit-4-self-check.html] +} \ No newline at end of file diff --git a/topic/nyc_bjc/5-algorithms.es.topic b/topic/nyc_bjc/5-algorithms.es.topic index 264c65aec0..f99a46d4a5 100755 --- a/topic/nyc_bjc/5-algorithms.es.topic +++ b/topic/nyc_bjc/5-algorithms.es.topic @@ -41,3 +41,8 @@ heading: Laboratorio 6: Tres en línea resource: Hacer que la computadora juegue estratégicamente [/bjc-r/cur/programming/5-algorithms/6-tic-tac-toe/4-making-computer-player-strategic.es.html] } +heading: (NEW) Unidad 5 Revision + resource: (NEW) Vocabulario [/bjc-r/cur/programming/5-algorithms/unit-5-vocab.es.html] + resource: (NEW) En el examen AP [/bjc-r/cur/programming/5-algorithms/unit-5-exam-reference.es.html] + resource: (NEW) Preguntas de autocomprobacion [/bjc-r/cur/programming/5-algorithms/unit-5-self-check.es.html] +} \ No newline at end of file diff --git a/topic/nyc_bjc/5-algorithms.topic b/topic/nyc_bjc/5-algorithms.topic index 68aeed785c..6b5329b51d 100755 --- a/topic/nyc_bjc/5-algorithms.topic +++ b/topic/nyc_bjc/5-algorithms.topic @@ -41,9 +41,8 @@ heading: Lab 6: Tic-Tac-Toe with a Computer Player resource: Making the Computer Play Strategically [/bjc-r/cur/programming/5-algorithms/6-tic-tac-toe/4-making-computer-player-strategic.html] //raw-html:
Draft Optional Project: Transitioning to Other Languages
- -heading: Unit 5 Review - resource: Vocabulary [/bjc-r/cur/programming/summaries/vocab5.html] - resource: On the AP Exam [/bjc-r/cur/programming/summaries/exam5.html] - resource: Self-Check Questions [/bjc-r/cur/programming/summaries/assessment-data5.html] -} +heading: (NEW) Unit 5 Review + resource: (NEW) Vocabulary [/bjc-r/cur/programming/5-algorithms/unit-5-vocab.html] + resource: (NEW) On the AP Exam [/bjc-r/cur/programming/5-algorithms/unit-5-exam-reference.html] + resource: (NEW) Self-Check Questions [/bjc-r/cur/programming/5-algorithms/unit-5-self-check.html] +} \ No newline at end of file diff --git a/topic/nyc_bjc/6-how-computers-work.es.topic b/topic/nyc_bjc/6-how-computers-work.es.topic index c76bf088a9..18b08cd798 100644 --- a/topic/nyc_bjc/6-how-computers-work.es.topic +++ b/topic/nyc_bjc/6-how-computers-work.es.topic @@ -22,3 +22,7 @@ heading: Laboratorio 2: Historia e impacto de las computadoras quiz: Ley de Moore [/bjc-r/cur/programming/6-computers/2-history-impact/2-moore.es.html] } +heading: (NEW) Unidad 6 Revision + resource: (NEW) Vocabulario [/bjc-r/cur/programming/6-computers/unit-6-vocab.es.html] + resource: (NEW) Preguntas de autocomprobacion [/bjc-r/cur/programming/6-computers/unit-6-self-check.es.html] +} \ No newline at end of file diff --git a/topic/nyc_bjc/6-how-computers-work.topic b/topic/nyc_bjc/6-how-computers-work.topic index 1b5fb8cc24..cfd643e2b2 100644 --- a/topic/nyc_bjc/6-how-computers-work.topic +++ b/topic/nyc_bjc/6-how-computers-work.topic @@ -23,8 +23,7 @@ heading: Lab 2: History of Computers quiz: Moore's Law [/bjc-r/cur/programming/6-computers/2-history-impact/2-moore.html] raw-html:
See comment on bottom of 6.1.9 regarding OPs. --MF, 6/12/20
- -heading: Unit 6 Review - resource: Vocabulary [/bjc-r/cur/programming/summaries/vocab6.html] - resource: Self-Check Questions [/bjc-r/cur/programming/summaries/assessment-data6.html] -} +heading: (NEW) Unit 6 Review + resource: (NEW) Vocabulary [/bjc-r/cur/programming/6-computers/unit-6-vocab.html] + resource: (NEW) Self-Check Questions [/bjc-r/cur/programming/6-computers/unit-6-self-check.html] +} \ No newline at end of file diff --git a/topic/nyc_bjc/7-recursion-trees-fractals.es.topic b/topic/nyc_bjc/7-recursion-trees-fractals.es.topic index 1267b7bcd2..966f95a477 100755 --- a/topic/nyc_bjc/7-recursion-trees-fractals.es.topic +++ b/topic/nyc_bjc/7-recursion-trees-fractals.es.topic @@ -20,3 +20,7 @@ heading: Laboratorio 2: Proyectos de recursividad resource: Mondrian recursivo [/bjc-r/cur/programming/7-recursion/2-projects/4-mondrian.es.html] } +heading: (NEW) Unidad 7 Revision + resource: (NEW) Vocabulario [/bjc-r/cur/programming/7-recursion/unit-7-vocab.es.html] + resource: (NEW) Preguntas de autocomprobacion [/bjc-r/cur/programming/7-recursion/unit-7-self-check.es.html] +} \ No newline at end of file diff --git a/topic/nyc_bjc/7-recursion-trees-fractals.topic b/topic/nyc_bjc/7-recursion-trees-fractals.topic index d1318e103e..37549db8e7 100755 --- a/topic/nyc_bjc/7-recursion-trees-fractals.topic +++ b/topic/nyc_bjc/7-recursion-trees-fractals.topic @@ -17,8 +17,7 @@ heading: Lab 2: Recursion Projects //raw-html: Koch snowflake resource: Lévy C-Curve Fractal [/bjc-r/cur/programming/7-recursion/2-projects/3-c-curve.html] resource: Recursive Mondrian [/bjc-r/cur/programming/7-recursion/2-projects/4-mondrian.html] - -heading: Unit 7 Review - resource: Vocabulary [/bjc-r/cur/programming/summaries/vocab7.html] - resource: Self-Check Questions [/bjc-r/cur/programming/summaries/assessment-data7.html] -} +heading: (NEW) Unit 7 Review + resource: (NEW) Vocabulary [/bjc-r/cur/programming/7-recursion/unit-7-vocab.html] + resource: (NEW) Self-Check Questions [/bjc-r/cur/programming/7-recursion/unit-7-self-check.html] +} \ No newline at end of file diff --git a/topic/nyc_bjc/8-recursive-reporters.topic b/topic/nyc_bjc/8-recursive-reporters.topic index 8bfc734514..da1b1291f0 100755 --- a/topic/nyc_bjc/8-recursive-reporters.topic +++ b/topic/nyc_bjc/8-recursive-reporters.topic @@ -34,7 +34,6 @@ heading: Optional Project: Sorting resource: Sorting a List [/bjc-r/cur/programming/8-recursive-reporters/optional-project-sorting/1-sorting-a-list.html] resource: Selection Sort [/bjc-r/cur/programming/8-recursive-reporters/optional-project-sorting/2-selection-sort.html] resource: Partition Sort [/bjc-r/cur/programming/8-recursive-reporters/optional-project-sorting/3-partition-sort.html] - -heading: Unit 8 Review - resource: Vocabulary [/bjc-r/cur/programming/summaries/vocab8.html] -} +heading: (NEW) Unit 8 Review + resource: (NEW) Vocabulary [/bjc-r/cur/programming/8-recursive-reporters/unit-8-vocab.html] +} \ No newline at end of file diff --git a/topic/sparks/1-functions-data.topic b/topic/sparks/1-functions-data.topic index 74c88d8210..10099aa305 100755 --- a/topic/sparks/1-functions-data.topic +++ b/topic/sparks/1-functions-data.topic @@ -58,3 +58,6 @@ heading: Lab 7: Dealing with Data Dos raw-html:

Unit 1 Project

Brian: Starter project has encrypt/decrypt functions. Student A chooses a password, uses the project to encrypt a text, then exports the encrypted text and sends that to student B, who imports it into their copy of the project (which doesn't include student A's key). Maybe have two cyphers in the project, one of which is simple substitution and therefore pretty easily breakable, and let kids break it, then use a more complicated cypher that's resistant to letter frequency attacks. I did a Playfair cypher in Computer Science Logo Style if anyone wants an example... Brian thinks it will be fun to break ciphers.

Implementing Vigen�re? (Maybe not exciting enough since everyone is doing the same thing?) Mary see https://www.geeksforgeeks.org/vigenere-cipher/ and https://www.khanacademy.org/computing/computers-and-internet/xcae6f4a7ff015e7d:online-data-security/xcae6f4a7ff015e7d:data-encryption-techniques/a/symmetric-encryption-techniques (from Pamela) --MF, 3/1/22

} +heading: (NEW) Unit 1 Review + resource: (NEW) Vocabulary [/bjc-r/sparks/student-pages/U1/unit-1-vocab.html] +} \ No newline at end of file diff --git a/topic/sparks/2-sequencing-iteration.topic b/topic/sparks/2-sequencing-iteration.topic index 89ddf70270..09fe767578 100755 --- a/topic/sparks/2-sequencing-iteration.topic +++ b/topic/sparks/2-sequencing-iteration.topic @@ -79,3 +79,6 @@ heading: Lab 4: Transmitting Data raw-html:

Unit 2 Project

User design as an end of unit project for U2 building on a project they’ve already built. Focus on "2-AP-15: Seek and incorporate feedback from team members and users to refine a solution that meets user needs." also some coverage of "2-CS-01: Recommend improvements to the design of computing devices, based on an analysis of how users interact with the devices." (also some documentation) --MF, 3/1/22

} +heading: (NEW) Unit 2 Review + resource: (NEW) Vocabulary [/bjc-r/sparks/student-pages/U2/unit-2-vocab.html] +} \ No newline at end of file diff --git a/topic/sparks/3-hardware.topic b/topic/sparks/3-hardware.topic index 80a95cca45..72d8daebac 100644 --- a/topic/sparks/3-hardware.topic +++ b/topic/sparks/3-hardware.topic @@ -37,3 +37,6 @@ heading: Lab 7: Collaborative Chain Reaction resource: Launch Day [/bjc-r/sparks/student-pages/U3/L7/04-launch-day.html] } +heading: (NEW) Unit 3 Review + resource: (NEW) Vocabulary [/bjc-r/sparks/student-pages/U3/unit-3-vocab.html] +} \ No newline at end of file diff --git a/utilities/build-tools/main.rb b/utilities/build-tools/main.rb index 3ce73f15de..3c36973d1a 100644 --- a/utilities/build-tools/main.rb +++ b/utilities/build-tools/main.rb @@ -44,10 +44,9 @@ def initialize(root: '', content: 'cur/programming', course: 'bjc4nyc', language @self_check = SelfCheck.new(@parentDir, language, content, @course) @atwork = AtWork.new(@parentDir, language, content) @testingFolder = false - @topic_folder = "" + @topic_folder = '' end - def language_ext @language_ext ||= @language == 'en' ? '' : ".#{@language}" end @@ -79,7 +78,7 @@ def Main end def topic_files_in_course - @topic_files_in_course ||= course.list_topics.filter { |file| file.match(/\d+-\w+/)} + @topic_files_in_course ||= course.list_topics.filter { |file| file.match(/\d+-\w+/) } end def clear_review_folder @@ -119,15 +118,13 @@ def deleteReviewFolder # TODO: should filter en/es separately. files = list_files("#{language_ext}.html") files.each do |file| - begin - File.open(file, mode: 'r') do |f| - f.close - File.delete(f) - end - rescue Errno::EACCES + File.open(file, mode: 'r') do |f| + f.close + File.delete(f) end + rescue Errno::EACCES end - + FileUtils.rm_rf(review_folder) end @@ -174,9 +171,8 @@ def is_topic_file?(file) def delete_existing_summaries(topic_file) all_lines = File.readlines(topic_file) - new_lines = "" + new_lines = '' all_lines.each do |line| - if line.match(/Unit \d+ Review/) || line.match(/Unidad \d+ Revision/) return File.write(topic_file, new_lines.strip) elsif line != '}' and line != '\n' @@ -185,22 +181,21 @@ def delete_existing_summaries(topic_file) end end - # Adds the summary content and links to the topic.topic file - def addSummariesToTopic(topic_file, curr_lab_folder) - topic_folder(topic_file.split("/")[0]) + def addSummariesToTopic(topic_file, _curr_lab_folder) + topic_folder(topic_file.split('/')[0]) topic_file_path = "#{@rootDir}/topic/#{topic_file}" delete_existing_summaries(topic_file_path) link_match = "/bjc-r/#{@content}" unit = File.readlines(topic_file_path).find { |line| line.match?(link_match) } link = extract_unit_path(unit, false, true) - list = [@vocab.vocab_file_name, - @self_check.exam_file_name, - @self_check.self_check_file_name].map {|f_name| f_name.gsub!(/\d+/, @unitNum)} + list = [@vocab.vocab_file_name, + @self_check.exam_file_name, + @self_check.self_check_file_name].map { |f_name| f_name.gsub!(/\d+/, @unitNum) } topic_resource = ["\tresource: (NEW) #{I18n.t('vocab')} [#{link}/#{list[0]}]", - "\n\tresource: (NEW) #{I18n.t('on_ap_exam')} [#{link}/#{list[1]}]", - "\n\tresource: (NEW) #{I18n.t('self_check')} [#{link}/#{list[2]}]"] + "\n\tresource: (NEW) #{I18n.t('on_ap_exam')} [#{link}/#{list[1]}]", + "\n\tresource: (NEW) #{I18n.t('self_check')} [#{link}/#{list[2]}]"] topic_content = <<~TOPIC heading: (NEW) #{I18n.t('unit_review', num: @unitNum)} TOPIC @@ -211,20 +206,19 @@ def addSummariesToTopic(topic_file, curr_lab_folder) is_empty_review = false end end - add_content_to_file(topic_file_path, "\n#{topic_content}\n}") if !is_empty_review - + add_content_to_file(topic_file_path, "\n#{topic_content}\n}") unless is_empty_review end def isSummary(line) !line.nil? && !@currUnit.nil? && line.match(@currUnit) end - #Writing new function to parse using the topic.rb file - #def parse_topic_page(file) + # Writing new function to parse using the topic.rb file + # def parse_topic_page(file) # path = "#{@rootDir}/topic/#{file}" # topic_runner = BJCTopic.new(path) # topic_json = topic_runner.parse - #end + # end # Parses through the data of the topic page and generates and adds content to a topics.txt # file that will be parsed later on to generate summaries @@ -298,9 +292,9 @@ def isTopic(arg) 'resource: Vocabulario', 'resource: En el examen AP', 'resource: Preguntas de Autocomprobacion', - "#{I18n.t('self_check')}", - "#{I18n.t('vocab')}", - "#{I18n.t('on_ap_exam')}"] + "#{I18n.t('self_check')}", + "#{I18n.t('vocab')}", + "#{I18n.t('on_ap_exam')}"] topicLine = /(\s+)?(\w+)+(\s+)?/ bool = true kludges.each do |item| @@ -311,9 +305,7 @@ def isTopic(arg) end def add_content_to_file(filename, data) - File.exist?(filename) ? f = File.open(filename, 'a') : f = File.new(filename, 'w') - f.write(data) - f.close + File.open(filename, mode: 'a+') { |f| f.write(data) } end # TODO: - if we have a BJCTopic class, this probably belongs there. @@ -393,7 +385,6 @@ def localPath local.join.to_s end - def extractTopicLink(line) labNamePattern = /----- / linkMatch = line.split(labNamePattern) @@ -405,10 +396,9 @@ def extractTopicLink(line) link.match(/(\w+-?)+\.html/) end lab.to_s - end - def extractTopicLinkFolder(line, use_root=true) + def extractTopicLinkFolder(line, use_root = true) labNamePattern = /----- / linkMatch = line.split(labNamePattern) link = if @language != 'en' @@ -417,11 +407,9 @@ def extractTopicLinkFolder(line, use_root=true) linkMatch[1].split(/(\w+-?)+\.html/) end use_root ? "#{localPath}#{link[0]}" : link[0] - end - - def extract_unit_path(line, use_root=true, is_topic=true) + def extract_unit_path(line, use_root = true, is_topic = true) if is_topic bracket_removed = line.split(/.+\[/) match = bracket_removed[1].split(/\]/).join.to_s @@ -429,17 +417,16 @@ def extract_unit_path(line, use_root=true, is_topic=true) match = line end link_with_lab = if @language != 'en' - match.split(/(\w+-?)+\.\w+\.html/) - else - match.split(/(\w+-?)+\.html/) - end - list = link_with_lab[0].split("/") - link = list.map { |elem, output = ""| output += ("/#{elem}") if list.index(elem) < list.length - 1}.join - link = link[1..link.length] if link[1] == "/" #get rid of extra slash, otherwise appears as //bjc-r + match.split(/(\w+-?)+\.\w+\.html/) + else + match.split(/(\w+-?)+\.html/) + end + list = link_with_lab[0].split('/') + link = list.map { |elem, output = ''| output += "/#{elem}" if list.index(elem) < list.length - 1 }.join + link = link[1..link.length] if link[1] == '/' # get rid of extra slash, otherwise appears as //bjc-r use_root ? "#{localPath}#{link}" : link end - def copyFiles list = [@vocab.vocab_file_name, @self_check.self_check_file_name, @self_check.exam_file_name] currentDir = Dir.pwd @@ -451,7 +438,6 @@ def copyFiles File.delete(dst) if File.exist?(dst) # TODO: use nokogiri to refomat the file. FileUtils.copy_file(src, dst) if File.exist?(src) - end Dir.chdir(currentDir) end @@ -468,19 +454,19 @@ def parse_units(topicsFile) labNamePattern = /-----/ unitNamePattern = /title: / endUnitPattern = /END OF UNIT/ - current_lab_folder = "" + current_lab_folder = '' i = 0 f.each do |line| if line.match(endUnitPattern) - current_unit_folder = current_lab_folder.split("/")[-2] + current_unit_folder = current_lab_folder.split('/')[-2] addSummariesToTopic(topic_files_in_course[topics_index], current_unit_folder) copyFiles topics_index += 1 end if !line.match(labNamePattern).nil? labFile = extractTopicLink(line) - root = @rootDir.split("/bjc-r")[0] - lab_path = "#{root}#{line.split(labNamePattern)[-1].split(" ")[-1]}" + root = @rootDir.split('/bjc-r')[0] + lab_path = "#{root}#{line.split(labNamePattern)[-1].split(' ')[-1]}" if labFile != '' current_lab_folder = extractTopicLinkFolder(line) if File.exist?(lab_path) @@ -555,4 +541,4 @@ def currUnit(str) def topic_folder(name) @topic_folder = name end -end \ No newline at end of file +end diff --git a/utilities/build-tools/rebuild-all.rb b/utilities/build-tools/rebuild-all.rb index 8cda883d8c..cc916ecfce 100755 --- a/utilities/build-tools/rebuild-all.rb +++ b/utilities/build-tools/rebuild-all.rb @@ -8,7 +8,7 @@ require_relative 'main' ROOT = '/bjc-r' -path = Dir.pwd ##ENV('PWD') +path = Dir.pwd # #ENV('PWD') puts path path = path.sub(%r{#{ROOT}/.*$}, ROOT) puts "Rebuilding all index/summaries from: #{path}"