Challenges

Factorial

The goal of this challenge is to create a program that calculates factorials.

Easy

Open the triangular numbers program and use it as a base.

Hard

Code the whole program from scratch.

Fibonacci ( Hard )

The goal of Fibonacci is to calculate the Fibonacci sequence.

Counter ( Easy )

Create a program that counts from 1 to a number

Add On

What about only even numbers

Very Picky Counter ( Medium )

Create a program say the first 10 numbers divisible by 3, 5, and 7

Documentation

  • Plus ( + )
  • Minus ( - )
  • Times ( * )
  • Divided by ( / )
  • Setting Variables
  • Getting Variables
  • Changing Variables Operations

Say

To put something in the response you do say and then the value for example to say one simply do say 1.

Math

There are 4 operators in bison basic:
  • Plus ( + )
  • Minus ( - )
  • Times ( * )
  • Divided by ( / )
Like in math times and divided by go first and then plus and minus so 1 + 1 * 2 would be 3

Plus

To do addition you use the + operator to do addition you could do one plus one like this 1 + 1.

Minus

To do subtraction you use the - operator to do subtraction you could do two minus one like this 2 - 1.

Times

To do multiplication you use the * operator to do multiplication you could do two times two like this 2 * 2.

Divided By

To do division you use the / operator to do division you could do four divided by two like this 4 / 2.

Variables

Variables are basically just pieces of data you can change.
  • Setting Variables
  • Getting Variables
  • Changing Variables Operations

Setting Variables

To set a variable to one you can do variable_name = 1

Getting Variables

To get a variable you can just write it\'s name like this say variable_name. You can even do math with it.

Changing Variables Operations

Plus Equals

Plus equals is a shorthand for setting variable to it plus something to do it you use += like this to add one to something variable_name += 1

Minus Equals

Minus equals is a shorthand for setting variable to it minus something to do it you use -= like this to subtract one to something variable_name -= 1

Times Equals

Times equals is a shorthand for setting variable to it times something to do it you use *= like this to multiply something by two variable_name *= 2

Divided By Equals

Divided by equals is a shorthand for setting variable to it divided by something to do it you use /= like this to divide something by two variable_name /= 2

Loops

To do something repeatedly you can use something called a loop. A loop does some code repeatedly which is very useful in programing. Here is how you do a loop in Bison Basic.
do:
say 0
:5 times
        
First you use do: then you put the code you want to do repeatedly and finally you put how many times you want to do it. For 5 times you do it like this :5 times
Tip:
You can do a loop with index like this
index = 1
do:
say index
index += 1
:5 times