I'm going to be iterating through a set of data and, depending on a filter, it may go into one variable or another (only two variables to be considered for this example). Each variable represents an HTML table.
I could do a big if-else, or iterate through the data twice, but I hate repeating code.
Is there a way to have the program say "If X, then use this variable for the remainder of this loop, and if !X, then use THIS variable" ?
Tao Te Ching Discussions : Chapter 9 (includes links to previous chapters)
What is the nature of conflict?
I could do a big if-else, or iterate through the data twice, but I hate repeating code.
Is there a way to have the program say "If X, then use this variable for the remainder of this loop, and if !X, then use THIS variable" ?
Tao Te Ching Discussions : Chapter 9 (includes links to previous chapters)
What is the nature of conflict?