Hi! I need help. Not on the coding part, but finding a pattern. I

Hi! I need help. Not on the coding part, but finding a pattern. I have to code an image where it is based on size. I have everything coded but cant figure out the pattern for lines.,,size 2 = 2,size 3 = 2,size 4 = 3,size 5 = 3,size 6 = 4,size 7 = 4,and so on…,can someone help me figure out the pattern? I’ve been trying to find one, but i can’t. in my code, i’m only allowed for use for and int, and static statements. I can’t use "if" statements, or anything above that. ,,Thanks!