{namespace planepage} /** * This is a Closure Template. * * See the README.txt for details. */ /** * Translated messages for use in JavaScript. */ {template .messages}
{msg meaning="Plane.rows" desc="page text - Total number of rows of seats on an airplane.\n\nParameters:\n* %1 - number of rows of seats on an airplane. It is always an integer greater than or equal to zero."}Rows: %1{/msg} {msg meaning="Plane.getRows" desc="block text - The number of rows on the airplane, to be used in a mathematical equation, such as: 'seats = 4 x '''rows (5)''''.\n\nParameters:\n* %1 - number of rows of seats on an airplane. It is always an integer greater than or equal to zero."}rows (%1){/msg} {msg meaning="Plane.rows1" desc="page text - The number of rows of first-class seats on the airplane. You can see the block at [http://blockly-share.appspot.com/static/apps/plane/plane.html?lang=en&level=3].\n\nParameters:\n* %1 - number of rows of first-class seats on an airplane. It is always an integer greater than or equal to zero."}1st class rows: %1{/msg} {msg meaning="Plane.getRows1" desc="block text - The number of rows of first-class seats on the, to be used in a mathematical equation. See [http://blockly-share.appspot.com/static/apps/plane/plane.html?lang=en&level=3].\n\nParameters:\n* %1 - number of rows of first-class seats on an airplane. It is always an integer greater than or equal to zero."}1st class rows (%1){/msg} {msg meaning="Plane.rows2" desc="page text - The number of rows of second-class seats on the airplane. %1 is an integer greater or equal to zero. See [http://blockly-share.appspot.com/static/apps/plane/plane.html?lang=en&level=3].\n\nParameters:\n* %1 - number of rows of second-class seats on an airplane. It is always an integer greater than or equal to zero."}2nd class rows: %1{/msg} {msg meaning="Plane.getRows2" desc="block text - The number of rows of second-class (also called 'economy class') seats on the airplane, to be used in a mathematical expression.\n\nParameters:\n* %1 - number of rows of second-class seats on an airplane. It is always an integer greater than or equal to zero."}2nd class rows (%1){/msg} {msg meaning="Plane.seats" desc="page text - The total number of seats on the airplane.\n\nParameters:\n* %1 - number of seats on an airplane. It is always either the next message or an integer greater than or equal to zero."}Seats: %1{/msg} {msg meaning="Plane.placeholder" desc="page text - A word or symbol indicating that this numeric value has not yet been determined."}?{/msg} {msg meaning="Plane.setSeats" desc="block text - The first half of a mathematical equation determining the number of seats in an airplane, such as: ''''seats =''' 4 x rows'."}seats ={/msg}
{/template} /** * Web page structure. */ {template .start} {call .messages /}

Blockly‏ >{sp} Demos‏ >{sp} {msg meaning="Plane.plane" desc="title - Specifies that this is Blockly's '''Plane''' (airplane) tutorial. The word 'plane' was chosen over 'airplane' in English because it is shorter and less formal."} Plane Seat Calculator {/msg} {sp} {sp} {for $i in range(1, $ij.maxLevel + 1)} {sp} {if $i == $ij.level} {$i} {else} {if $i < $ij.level} {else} {$i} {/if} {/if} {/for}

{if $ij.level > 1} {/if}

{switch $ij.level} {case 1} {msg meaning="Plane.description1" desc="instructions - Note that in [http://blockly-share.appspot.com/static/apps/plane/plane.html?lang=en&level=1 this level], there is only one type of seat on the plane."}An airplane has a number of rows of passenger seats. Each row contains four seats.{/msg} {case 2} {msg meaning="Plane.description2" desc="instructions - Note that in [http://blockly-share.appspot.com/static/apps/plane/plane.html?lang=en&level=2 this level], there are two types of seats on this plane."}An airplane has two seats in the flight deck (for the pilot and co-pilot), and a number of rows of passenger seats. Each row contains four seats.{/msg} {case 3} {msg meaning="Plane.description3" desc="instructions - Note that in [http://blockly-share.appspot.com/static/apps/plane/plane.html?lang=en&level=3 this level], there are three types of seats on this plane. Be sure to use the same terms for '1st class' and '2nd class' as you did for the earlier messages."}An airplane has two seats in the flight deck (for the pilot and co-pilot), and a number of rows of 1st class and 2nd class passenger seats. Each 1st class row contains four seats. Each 2nd class row contains five seats.{/msg} {/switch}

{msg meaning="Plane.instructions" desc="page text - This text appears below the airplane graphic and above the space for the user to create the formula. The number of rows an the graphic may be changed by the user with a slider. See [http://blockly-share.appspot.com/static/apps/plane/plane.html?lang=en&level=1] for a picture."}Build a formula (below) that calculates the total number of seats on the airplane as the rows are changed (above).{/msg}

{call .toolbox /}
{/template} /** * Toolboxes for each level. */ {template .toolbox} {/template}