Sep-19-2018, 03:42 AM
(Sep-19-2018, 03:20 AM)ichabod801 Wrote: Please use Python tags when posting code. See the BBCode link in my signature below for instructions.
I'm not totally sure what the tree of questions is going to look like, but you might think about something like this:
offset_left_or_right = input("Which side of the transition is offset? Left or Right? ") query = "Is bottom {} going up to the left or right? " bot_corner_to_left_or_right = input(query.format(offset_left_or_right))This allows you to modify the question being asked, and store where the bottom corner is going, regardless of which corner it is.
We often have to tell new programmers to use more descriptive variable names. That's not a problem here, but I think you're over doing it. I seen guidelines saying that variable names start to be a problem when they are longer than 12 to 15 characters. Take offset_left_or_right. It seems you are just adding the possible values. Unless it needs to be clarified that it's not some other offset, I would just call it offset.
im sorry, but i dont actually see that edit button anymore or i would change it. However i have long names because i have to ask the offset, if it offsets left or right, top offset, and bot offset. If it offset on left side i have to ask if bottom left offsets up and to the left or right, and if it offsets on right i need to ask the same thing for the right. i would love for them to be shorter however i want to make sure i know what every tag is for. i quickly put this code in, and it looks like it should work.
[python] offset_left_or_right = input("Which side of the transition is offset? Left or Right? ") query = "Is bottom {} going up to the left or right? " bot_corner_to_left_or_right = input(query.format(offset_left_or_right))[/python]
how would i take there second answer and save it as bot_corner_up_to_left or bot_corner_up_to_right depending on what they answer. so that i the equation would know that they typed in left and would save it as bot_corner_up_to_left. Sorry i dont want you to have to write it all for me, but i have been looking all night for some way to do it.