Try the numbers from 8 through 15 to see what colors you get. Basically, if you add 8 to any of the above colors, you get brighter versions of the same color. Take blue which is 1 and add 8 and you get 9 which is bright blue. Blinking Adding 16 to a color number gives you a blinking version.
You could start setting them up for binary search and more efficient data structures by having them perform something relatively complex e.
Have fun Dice and randomness often adds to the fun as in these ideas from my good friend Debbie Carter.
The addition of graphing is a great interest builder and allows for some more complex projects later on in a course. Use the elements of an array to tally a series of events.
Students can then display the results in a bar graph or histogram. Olive High School Flanders, NJ Brian Spotts also suggested a dice related project that honestly I think could use more detail but maybe it makes sense to you.
Have them roll a die a number of times and count them. Here is one such idea: I have an exercise where students set up a simple int array and then simulate a "random" walk using a coin flip. The initial position is the middle of the array and if the coin flip is heads 0 move 1 step to the right, tails 1 move one cell to the left.
Each time they move into a cell the cell is incremented.
After flipping the coin a given number of times they then need to print out the total number of times the cell was occupied. I use this exercise to get at a number of topics: George Murkowski, Upper School Technology Facilitator, The Wheeler School Mathematical challenges are often good as are exercises that requires any kind of searching for thing; Another project might be something along the lines of "Given an array of integers maybe using Math.
For something a bit more challenging, you could implement a simple "lookup code" array, where a sample string can be encoded by the use of a secondary String array as a lookup table.
Encode the String "hello" by using the nth letter "above" each letter as an encryption scheme Repeat this for all letters in the array to encode the String. And follow her blog — she has lots of great ideas.
Now there is a subject most high school students can relate to. I like that this project as a sort of puzzle aspect to it as well.
Locker Problem arrays — Write a program to simulate the following experiment.
You have closed lockers. Start with the first locker and for every locker open it. Now, starting with the second locker, for this locker and every second locker after that, if the locker is open, close it; if it is closed, open it.
Then, starting with the third locker, for this locker and every third locker after that, if the locker is open, close it; if it is closed, open it. Print out the locker numbers that remain open. What do you notice about the lockers that remain open? Can you explain your results?
I have my students do a version of "Duck Duck Goose". A Boolean array is set up with all elements being initialized to true.
Every third player is eliminated, only counting players that are still true. They need to keep track of the number of "trues" until it gets to 3, and change that player to false. Also need to skip over falses.Jul 08, · hi, everyone how to write a script to generate Fibonacci series?
Fibonacci serious will work correctly if you assign the value like a=0,b=1 and also remove the print c before the while loop, then the output will display correct fibonacci series. Fibonacci Numbers , not factorised) There is a complete list of all Fibonacci numbers and their factors up to the th Fibonacci and th Lucas numbers and partial results beyond that on Blair Kelly's Factorisation pages 0 1 --the series starts like this.
0+1=1 so the series is now 0 1. Recursive Sequences and Fibonacci Sequences In this discussion we will see how matrices can be used to describe recursive sequences, in particular Fibonacci numbers. Recall that a recursively defined sequence is a sequence where the first one or more values are given along with a formula that relates the n th term to the previous terms.
While loop, Find the Fibonacci series, Fibonacci series in Java.
Fibonacci was not the first to know about the sequence, it was known in India hundreds of years before! About Fibonacci The Man His real name was Leonardo . Golden Ratio, Phi, , and Fibonacci in Math, Nature, Art, Design, Beauty and the Face.
One source with over articles and latest findings. Phi; Design/Art; Beauty/Face; this illustrates the significance of the additive property of the Fibonacci series that allows us to derive phi from the ratios of the successive numbers.