Skip to content

Conversation

@made-line
Copy link

Binary and Decimal

Congratulations! You're submitting your assignment.

Comment on lines +7 to +9
binary_array = []

8.times {binary_array << rand(0..1)}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
binary_array = []
8.times {binary_array << rand(0..1)}

return sum
end

print binary_to_decimal(binary_array)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
print binary_to_decimal(binary_array)


8.times {binary_array << rand(0..1)}

def binary_to_decimal(binary_array)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍 Well done

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants