We are about to switch to a new forum software. Until then we have removed the registration on this forum.
Say I have three types of circle, c1, c2 and c3 with different sizes (to be inputted by user) and I am to place them randomly in a specific size (to be inputted by user) of rectangle. The problem is how many of c1, c2 and c3 will fit that rectangle while maximizing space? Also, c1 type of circles have to be a specific distance apart.
Answers
This is a forum for the Processing programming language, not C.
It is unlikely anyone here will do your homework for you.
Perhaps you should try coding this yourself in processing! It's quite easy.
Start by getting the user input...
I agree
Also why placing randomly? For packing a random is not helpful. And they are non overlapping I guess
Remark: user input of 3 numbers in a row is one of the hardest things for beginners in processing imho.
It's possible of course but it's clumsy. Processing is just not meant for those kind of stuff....
@Tfguy, I posted it here because I emailed someone in youtube about this and he askee me to post here. I'm sorry.
@Chrisir, yes it's nonoverlapping.
I thought random placement is easier like
No matter whether it's C or processing those packing problems are not too easy
Start by reading a Wikipedia article and google it
This might or might not be helpful: https://forum.processing.org/two/discussion/23429/adding-shapes-without-overlapping#latest
Ignore if you don't find any value.
Kf
Okay thanks, everyone!