September 2017 Update
This commit is contained in:
parent
bba7bfd280
commit
ba8067c3b7
14570 changed files with 153136 additions and 63871 deletions
|
|
@ -1,20 +1,19 @@
|
|||
#import system.
|
||||
#import extensions.
|
||||
import extensions.
|
||||
|
||||
#class(extension) testOp
|
||||
extension testOp
|
||||
{
|
||||
#method bitwiseTest : y
|
||||
bitwiseTest : y
|
||||
[
|
||||
console writeLine:self:" and ":y:" = ":(self and:y).
|
||||
console writeLine:self:" or ":y:" = ":(self or:y).
|
||||
console writeLine:self:" xor ":y:" = ":(self xor:y).
|
||||
console writeLine:"not ":self:" = ":(self inverted).
|
||||
console writeLine:self:" shr ":y:" = ":(self shift &index:y).
|
||||
console writeLine:self:" shl ":y:" = ":(self shift &index:(y negative)).
|
||||
console printLine(self," and ",y," = ",self and:y).
|
||||
console printLine(self," or ",y," = ",self or:y).
|
||||
console printLine(self," xor ",y," = ",self xor:y).
|
||||
console printLine("not ",self," = ",self inverted).
|
||||
console printLine(self," shr ",y," = ",self shiftRight:y).
|
||||
console printLine(self," shl ",y," = ",self shiftLeft:y).
|
||||
]
|
||||
}
|
||||
|
||||
#symbol program =
|
||||
program =
|
||||
[
|
||||
console readLine:(Integer new) bitwiseTest:(console readLine:(Integer new)).
|
||||
console readLineTo(Integer new); bitwiseTest(console readLineTo(Integer new)).
|
||||
].
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue