Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 Site Related Forums
 The Yak Corral
 Evening challenge to Starting Members :-)

Author  Topic 

RatTail
Crackhead

98 Posts

Posted - 2003-04-18 : 14:39:08
Guess how and continue the sequence:

11, 31, 41, 61, 71, 101, 131, ...

========================================
Warning in Zoo:
Do Not frighten emus for the floor is made of concrete.


nr
SQLTeam MVY

12543 Posts

Posted - 2003-04-18 : 14:51:01
OK - it's a bit sad using sql for this but (and what about 1?)

i
-----------
1
11
31
41
61
71
101
131
151
181
191
211
241
251
271
281
311
331
401
421
431
461
491
521
541
571
601
631
641
661
691
701
751
761
811
821
881
911
941
971
991


==========================================
Cursors are useful if you don't know sql.
DTS can be used in a similar way.
Beer is not cold and it isn't fizzy.
Go to Top of Page

RatTail
Crackhead

98 Posts

Posted - 2003-04-18 : 15:01:07
Sorry. You are wrong. And let's forget about '1'.

Go to Top of Page

nr
SQLTeam MVY

12543 Posts

Posted - 2003-04-18 : 15:10:37
Wrong?
Well maybe not the sequence you are expecting.
Actually you can form a sequence of any numbers and generate a formula for it so anything could follow your sequence.

Usually it's stated as following the simplest solution.
Guess I'll have to find more solutions and will argue about the simplest later (be warned).

==========================================
Cursors are useful if you don't know sql.
DTS can be used in a similar way.
Beer is not cold and it isn't fizzy.
Go to Top of Page

nr
SQLTeam MVY

12543 Posts

Posted - 2003-04-18 : 15:19:43
These all fit (but aren't as simple as the first one I gave)

11, 31, 41, 61, 71, 101, 131, 151, 181, 191, 211, 221, 241, 251, 271, 281, 311, 331, 361, 391, 401, 421, 431, 461, 481, 491, 521, 541, 551, 571, 601, 611, 631, 641, 661, 691, 701, 731, 751, 761, 811, 821, 841, 851, 871, 881, 901, 911, 941, 961, 971, 991

11, 31, 41, 61, 71, 101, 131, 151, 181, 191, 211, 241, 251, 271, 281, 311, 331, 361, 391, 401, 421, 431, 461, 491, 521, 541, 551, 571, 601, 631, 641, 661, 691, 701, 731, 751, 761, 811, 821, 841, 851, 881, 901, 911, 941, 961, 971, 991

11, 31, 41, 61, 71, 101, 131, 151, 181, 191, 211, 241, 251, 271, 281, 311, 331, 361, 401, 421, 431, 461, 491, 521, 541, 551, 571, 601, 631, 641, 661, 691, 701, 751, 761, 811, 821, 841, 851, 881, 911, 941, 961, 971, 991


==========================================
Cursors are useful if you don't know sql.
DTS can be used in a similar way.
Beer is not cold and it isn't fizzy.
Go to Top of Page

RatTail
Crackhead

98 Posts

Posted - 2003-04-18 : 15:45:55
Sorry. Sorry. Wrong. Wrong.
No my fault in this. It's taken from a book on maths.


Go to Top of Page

tkizer
Almighty SQL Goddess

38200 Posts

Posted - 2003-04-18 : 15:49:17
quote:

Sorry. Sorry. Wrong. Wrong.
No my fault in this. It's taken from a book on maths.



Well actually he is not wrong. There are many answers to it. The book that you are getting this from has one possible answer. nr has posted other possible answers.

BTW, this is a SQL forum and not a Math forum. Yes this can be done with SQL, but it isn't a SQL question.

Tara
Go to Top of Page

RatTail
Crackhead

98 Posts

Posted - 2003-04-18 : 16:46:12
2nr
Take my apologies. Of course the very first your answer is OK.
Something happened with my dividing ability at the night.

2tduggan
What a jealous thing you are, man from USA.
SQL Cerber fits to you as your Custom title...
(and so on)



Go to Top of Page

jsmith8858
Dr. Cross Join

7423 Posts

Posted - 2003-04-18 : 16:50:48
Nr --- doesn't it make sense to post your algorithm? I am not getting much from looking at a list of numbers.

For me, all I can think of is:

Prime numbers, where the last digit is "1".

Tara --

quote:

BTW, this is a SQL forum and not a Math forum. Yes this can be done with SQL, but it isn't a SQL question.



It's the YAK corral. he's just posting a brian teaser. I see nothing wrong with that! You're free to ignore all posts you choose not to read.




- Jeff
Go to Top of Page

tkizer
Almighty SQL Goddess

38200 Posts

Posted - 2003-04-18 : 17:07:42
RatTail,

My title is not a custom title. You'll get the same title if you ever reach over 500 posts. Also, I'm not a man, I'm a woman. Women are in the SQL Server field too.


Jsmith8858,

I realize it's the Yak Corral, but he keeps saying that nr is wrong and he isn't so I was just reacting back.


Tara
Go to Top of Page

nr
SQLTeam MVY

12543 Posts

Posted - 2003-04-18 : 17:37:17
First one I posted was prime numbers ending in one.
Rest were numbers ending in 1 not divisible by anything up to 11, 13, 17.

Happy to be told this isn't the answer - there are infinite possibilities (and not just aleph null), just a matter of finding the right one.

==========================================
Cursors are useful if you don't know sql.
DTS can be used in a similar way.
Beer is not cold and it isn't fizzy.
Go to Top of Page

RatTail
Crackhead

98 Posts

Posted - 2003-04-18 : 18:20:46
Dedicated to Tara, the best woman in the SQL Server field.

As ever I was wrong...
And everyone is right...
Who can explain me these
Unjustice and Unkind?
Oh, Tara! Only you
Can help me in the night!
Oh, Tara! Only you
Can save me from my dark!

==============
Voila.


Go to Top of Page

tkizer
Almighty SQL Goddess

38200 Posts

Posted - 2003-04-18 : 18:23:24
quote:

Dedicated to Tara, the best woman in the SQL Server field.

As ever I was wrong...
And everyone is right...
Who can explain me these
Unjustice and Unkind?
Oh, Tara! Only you
Can help me in the night!
Oh, Tara! Only you
Can save me from my dark!

==============
Voila.



Wow! Or were you just being sarcastic? Either way, thanks for the poem!

Tara
Go to Top of Page

nr
SQLTeam MVY

12543 Posts

Posted - 2003-04-18 : 19:38:04
And just to show that it is something to do with sql
(delete the 1 yourself).

set nocount on
create table #a (i int)

declare @i int
select @i = 1
while @i <= 1000
begin
insert #a select @i
select @i = @i + 1
end

select @i = 1
while @i*(@i-1) <= (select max(i) from #a)
begin
select @i = min(i) from #a where i > @i
delete #a where i%@i=0 and i <> @i
end
delete #a where right(convert(varchar(10),i),1) <> '1'

declare @s varchar(4000)
select @s = coalesce(@s + ', ','') + convert(varchar(10),i) from #a
select @s

drop table #a


==========================================
Cursors are useful if you don't know sql.
DTS can be used in a similar way.
Beer is not cold and it isn't fizzy.
Go to Top of Page

Merkin
Funky Drop Bear Fearing SQL Dude!

4970 Posts

Posted - 2003-04-18 : 21:18:01
RatTail

Please don't insult any more people on SQLTeam. We are getting sick of that crap and you won't be welcome here anymore if you do it again.

Secondly, if you are going to post problems you don't understand (and we rather you don't) don't tell people they are wrong when their answers don't match the book you have.

Damian
Go to Top of Page

RatTail
Crackhead

98 Posts

Posted - 2003-04-19 : 05:17:44
2Tara
Of course I did not put in it any sarcasm. Moreover,
in general I hate any sarcasm and irony. I just was
trying to express my admiration and, to some extent,
my apologies. Plus, all this in old-fashion manner...

2Merkin
My obsessive 'wrong', 'wrong' was just my temporary
block of reason, nothing more. And this trouble is
familiar to each of us, isn't it?
Then, you have mentioned the word 'problem'... A bit
sudden and perplexing like... It's supposed to be just
a innocent para-maths joke (this fact can be easily
inferred from the subject of the topic).
Anyway I got what you said.

======================================================
While on doping-test it turned out that an australian
triple-jumper was a men-clothes-worn kangaroo.


Go to Top of Page

Tim
Starting Member

392 Posts

Posted - 2003-04-21 : 09:39:55
what a nice poem - is it from a book on poetry ratty, or one of your own??

I googled it to no avail, but perhaps it is a transalation from russian? Excuse me please if you are not russian - "USSR" leaves me unclear as to your nationality.


PS merkin do you want to borrow my pills?

Go to Top of Page

Merkin
Funky Drop Bear Fearing SQL Dude!

4970 Posts

Posted - 2003-04-21 : 09:50:26
Why Tim ? What do they do ?

Perhaps you are inferring that I am on a power trip again ? (In public this time though).

I'm not trying to be on a power trip, I am just sick of idiots insulting people on SQL Team. We let Public idiot#1 off the hook time after time. Until finally he posted some really nasty stuff, and we got backlash for not acting sooner.

In that little flurry of activity, RatTail also posted some stuff that got moved from public view and was asked nicely to stop. Now I have asked him again.

No one wants the insults in this forum to get back to the point where it is offensive to valued contributers.

If you think that is me on a power trip, you are entitled to your opinion, I don't really care.

Damian


Edited by - merkin on 04/21/2003 10:00:05
Go to Top of Page

Tim
Starting Member

392 Posts

Posted - 2003-04-21 : 09:55:11
keep you awake all night

Go to Top of Page

X002548
Not Just a Number

15586 Posts

Posted - 2003-04-21 : 10:04:01
I really just don't get it......I thought techies were a different breed..

Merkin and Rob, Thanks for doing a Thankless job...



Brett

8-)
Go to Top of Page

Ledell
SQL NASCAR Parsing Chick

107 Posts

Posted - 2003-04-21 : 11:16:12
quote:


Merkin and Rob, Thanks for doing a Thankless job...




Yes! Thank you for your assistance and guidence. Don't want to forget Justin or Graz either!

Thank you very much!



*************************
Got some code from Rob. Can anyone help?
Go to Top of Page
    Next Page

- Advertisement -