Chapter 8: Application Examples

Digital dice

This program simulates rolling of multiple dice. You can play a dice game without dice or where there is not enough space to roll dice.

At the first stage, ask the number of dice to use for play. Secondly, roll dice and display the result and wait until any key is pressed.

1.Press b 210to open a window for creating a NEW program.

2.Type DICE for the title then press e.

A NEW program called ‘DICE’ will be created.

3.Enter the program as follows.

Program code

Key operations

Print”NO OF DICE

i 1 @ a NO s OF

 

s DICE ; e

 

 

Input N

i 2 ; N e

 

 

Label PLAY

i 6 @ a PLAY ; e

 

 

M=1

; M ; = 1 e

 

 

X=0

; X ; = 0 e

 

 

Label ROLL

i 6 @ a ROLL ; e

 

 

X=X+r.dice

; X ; = ; X + @

 

w 1 e

 

 

M=M+1

; M ; = ; M + 1 e

 

 

If M<=N Goto ROLL

i 8 ; M i E ; N

 

; s i 9 @ a

 

ROLL ; e

 

 

Print X

i 0 ; X e

 

 

Wait

i 3 e

 

 

Goto PLAY

i 9 @ a PLAY ; e

 

 

Running the program

4.Press j to return to the PROG mode menu.

5.Press 0, select the program ‘DICE’ and press e.

6.Enter the number of dice to play and press e.

7.Press e (or any other key) to continue to play. Press j to quit.

106

Page 108
Image 108
Sharp EL-5250, EL-5230 operation manual Digital dice

EL-5230, EL-5250 specifications

The Sharp EL-5250 and EL-5230 are advanced scientific calculators that cater to students, professionals, and anyone in need of a reliable tool for complex calculations. Both models are designed with a blend of functionality, portability, and user-friendliness, making them excellent choices for math and engineering tasks.

The Sharp EL-5250 is equipped with a wide range of features ideal for higher-level calculations. It supports over 500 functions, including trigonometric, exponential, logarithmic, and statistical computations. The calculator also includes built-in memory functions, allowing users to store and recall values effortlessly. The large, easy-to-read LCD display can present multiple lines of data simultaneously, enhancing clarity and reducing the need for repetitive calculations.

On the other hand, the EL-5230, while slightly less advanced, still offers a robust set of functions. This model is particularly well-suited for students in high school or early college, providing essential functionalities for algebra, geometry, and basic statistics. Its 240 functions cover a variety of mathematical disciplines, making it a versatile option for different educational needs.

Both calculators feature Sharp's unique "MathPrint" technology, which is a standout characteristic allowing users to view fractions, square roots, and other expressions in a format more akin to traditional textbook layouts. This technology greatly enhances comprehension and usability, particularly for visual learners.

The calculators are powered by dual power sources, utilizing both solar and battery power, ensuring reliability in diverse environments. The compact and lightweight design of the EL-5250 and EL-5230 makes them highly portable. Users can easily carry them in a backpack or briefcase without added bulk.

Durability is another aspect where Sharp excels. The calculators are built to withstand regular use, featuring a sturdy exterior. Additionally, Sharp provides a protective cover that helps prevent damage during transport, making these calculators a long-term investment for users.

In summary, both the Sharp EL-5250 and EL-5230 deliver exceptional performance with their extensive features and advanced technology. They are perfect for those who require reliable and efficient tools for various mathematical tasks, whether in education or professional settings. With their user-friendly designs and durability, these calculators continue to be reliable companions for anyone working with numbers.