122-32000 Parallax Inc, 122-32000 Datasheet - Page 302
122-32000
Manufacturer Part Number
122-32000
Description
MANUAL PROPELLER
Manufacturer
Parallax Inc
Specifications of 122-32000
Accessory Type
Manual
Lead Free Status / RoHS Status
Lead free / RoHS Compliant
For Use With/related Products
Propeller Education (PE) Kit
Lead Free Status / Rohs Status
Lead free / RoHS Compliant
- Current page: 302 of 438
- Download datasheet (5Mb)
Using RETURN
The
DisplayDivByZeroError
PUB Add(Num1, Num2)
PUB Divide(Dividend, Divisor)
The
RETURN
RETURN
in at the end of any methods that don’t have one.
The
DisplayDivByZeroError
method to return with the value 0. If, however, the
return Dividend / Divisor
division. This is an example where the last
return the result all in one step rather than separately affecting the built-in
beforehand.
Page 302 · Propeller Manual v1.0
Result := Num1 + Num2
return
if Divisor == 0
return Dividend / Divisor
Add
DisplayDivByZeroError
return 0
Divide
following
. The
was not really required because the Propeller Tool Compiler will automatically put it
method sets its built-in
– Spin Language Reference
method checks the
RETURN
example
causes
is a method defined elsewhere.
method and then executes
Add
, which causes the method to return with the result of the
demonstrates
to return the value of
RESULT
Divisor
variable equal to
RETURN
value.
two
Divisor
return 0
'Add Num1 + Num2
'Check if Divisor = 0
'If so, display error
'and return with 0
'Otherwise return quotient
was used to perform the calculation and
uses
If
RESULT
Divisor
was not equal to zero, it executes
of
, which immediately causes the
Num1
to the caller. Note that this
RETURN
plus
equals zero, it calls a
.
Num2
, then executes
RESULT
Assume
variable
that
Related parts for 122-32000
Image
Part Number
Description
Manufacturer
Datasheet
Request
R
Part Number:
Description:
MANUAL FOR SUMOBOT
Manufacturer:
Parallax Inc
Datasheet:
Part Number:
Description:
GUIDE STUDENT PROCESS CONTROL
Manufacturer:
Parallax Inc
Datasheet:
Part Number:
Description:
GUIDE STUDENT SMART SENSORS
Manufacturer:
Parallax Inc
Datasheet:
Part Number:
Description:
LEAD WIRES FLYING CABLE III/IV
Manufacturer:
Xilinx Inc
Datasheet:
Part Number:
Description:
BOARD ADAPTER AND FLY LEADS
Manufacturer:
Xilinx Inc
Datasheet:
Part Number:
Description:
PLATFORM CABLE USB II
Manufacturer:
Xilinx Inc
Datasheet:
Part Number:
Description:
KIT STARTER COOLRUNNER-II BUNDLE
Manufacturer:
Xilinx Inc
Datasheet:
Part Number:
Description:
Microcontroller Modules & Accessories DISCONTINUED BY PARALLAX
Manufacturer:
Parallax Inc
Part Number:
Description:
Microcontroller Modules & Accessories DISCONTINUED BY PARALLAX
Manufacturer:
Parallax Inc
Part Number:
Description:
BOOK UNDERSTANDING SIGNALS
Manufacturer:
Parallax Inc
Datasheet:
Part Number:
Description:
BOARD EXPERIMENT+LCD NX-1000
Manufacturer:
Parallax Inc
Datasheet:
Part Number:
Description:
IC MCU 2K FLASH 50MHZ SO-18
Manufacturer:
Parallax Inc
Datasheet: