Click here to Skip to main content
15,879,096 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
I want an algorithm that give me the best dimension of a rectangular to put a number of it in a container rectangular !!
So the input for this algorithm is:
Height : is the height of the container
Width : is the width of the container
N : is the required number of rectangular to be fit in the container

the output is:
h: the height of the small rectangular
w: is the width of the small rectangular
Posted
Comments
Captain Price 27-Oct-13 11:46am    
So you want to divide a rectangle to N number of equal smaller rectangles ?
firas_hamzeh 27-Oct-13 17:16pm    
yes that is but I want the small rectangular to achieve some condition like:
H/W = 3/5

1 solution

 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900