Homework Questions? Ask a Tutor for Answers ASAP
Well, almost. What if the numbers are not in sequence? Would your query for 1,10,20 be expected to match this:
? We can still solve it, albeit more sloppily; I just need to know the PRECISE semantic, as they say.
In response to earlier question, yes, but, well, not exactly. Purpose same, mechanism different. We wouldn't sort all those to look for these; we would instead look for those in sorted variants of these. Same zebra, different stripes.
Just wondering about your actual application here--not that it's any of my business. Are you, like, a state organization tracking winning lottery combinations, or some such?
Fair enough. Kindly share with me why it's useful to hunt for a random set of numbers within a longer set of numbers as an "odds and statistics" application.
Post a spreadsheet, and you've got it. It's not complicated, it's just sloppy.
Still need to know what possible pratical application this has--for my own curiosity.
Surely you realize that random numbers will occur randomly. If you're trying to predict something from which you'll make money, it ain't gonna happen.
How about the following interface:
You type the numbers that you're looking for into a set of from one to five neighboring cells, that is,
M1 and maybe also N1 and maybe also O1 and maybe also P1 and maybe also Q1
They don't have to be in order; they don't have to have leading zeroes
Magic is automatically performed
The spreadsheet is then automatically embellished so that every matching row has a "Y" (for "yes") displayed next to it, while non-matching rows don't. Or--you could just get a count of how many rows matched displayed in some other cell.
That ain't computer lingo. How are you going to specify what numbers you want to search for unless you type them into somewhere? Did you expect the computer to read your mind, perhaps? Impossible to help you if I suggest a solution and your response is "I don't speak computer lingo." Without specifying what we're talking about, no progress is achievable. Come, now!You seem not to be happy with any attempt at terminological precision. Do we not use terms and jargon with rigorous precision in ALL the sciences? Not sure how you're going to achieve your goals in statistics without resorting to jargon and lingo.
Populating a fresh column by grabbing the matching sets and reformatting them tightly will take macros. Won't be compatible with all versions. Sending the spreadsheets here and there, firewalls will disable them.
If you're happy with matches indicated by a "Y" or "YES," it's very straightforward and quick as a flash to execute. It will look like this:
Donning flip-flops and grabbing umbrella and lantern to head down to main pool and attempt to score sodas and snacks before vending machines die pursuant to electrical problems attending approaching hurricane.
Oh. Seems to me it does precisely the same thing, identifying every match--especially as you weren't really sure what you wanted, dismissing my attempts to characterize it as 'lingo" ;-)
I also figured that one line of code that wouldn't be disabled by every intervening firewall would be better than forty lines' worth of VBA macros.
I guess you prefer the problem to remain unsolved. O.K.