***Sorry this is my 1st time here, if this has been posted before please point me to the correct post as I can't find searching the site also if in wrong forum please move this thread***
hello again,
I am after some help with developing a quiz that gives random 8-bit binary numbers (eg 0000000 to 11111111) in which the student has to type in the correct decimal number conversion
However the issue I have is when I try this, it creates numbers that are not binary numbers for example you can't have a number 2 in the sum eg 11100200
I only want the 1's and 0's to be randomised?
Does anyone know how to setup the formula for this for a calculated question and to work in the dataset.
many thanks in advance
John
*Also if you need more information please ask and I will try and add this
I have had a look at this and managed to do it this way.
In the question text put:
What is the decimal alternative for the binary number below.
{a}{b}{c}{d}
and then for the correct answer formula put:
bindec({a}{b}{c}{d})
then for the dataset I set the range of values for parameter a to be 0 and 1 ( no decimals places of course)
set the same for parameter b, c, d etc
I had a problem when adding the new items ie adding 10 and found that if the one generated commenced with a 0 or more than one 0 it would not work BUT if I added them individually and deleted any starting with 0's it worked fine. Obviously this took longer but only had to be done once.
I will have fun looking more at this and reply more if I find out how. Hope this might be a starting point for you to have a solution.
I only started with 4 items but of course it could be increased for testing larger binary numbers.
Kathy
Am I missing something in the formula to allow leading zero in a calculation?
many thanks
John
Give the decimal equivalent of {=decbin({a})}
and use {a} as the formula (min 1, max 128).
Pierre