Click here to Skip to main content
15,891,976 members
Home / Discussions / C#
   

C#

 
AnswerRe: Threads, Socket and StateObject Pin
S. Senthil Kumar9-Sep-05 22:15
S. Senthil Kumar9-Sep-05 22:15 
GeneralRe: Threads, Socket and StateObject Pin
tekken2210-Sep-05 4:12
tekken2210-Sep-05 4:12 
GeneralRe: Threads, Socket and StateObject Pin
S. Senthil Kumar10-Sep-05 4:40
S. Senthil Kumar10-Sep-05 4:40 
QuestionMath troubles Pin
KaptinKrunch9-Sep-05 15:02
KaptinKrunch9-Sep-05 15:02 
AnswerRe: Math troubles Pin
S. Senthil Kumar9-Sep-05 22:19
S. Senthil Kumar9-Sep-05 22:19 
AnswerRe: Math troubles Pin
Member 19610719-Sep-05 23:04
Member 19610719-Sep-05 23:04 
AnswerRe: Math troubles Pin
Andy Brummer10-Sep-05 6:33
sitebuilderAndy Brummer10-Sep-05 6:33 
AnswerRe: Math troubles Pin
KaptinKrunch10-Sep-05 8:39
KaptinKrunch10-Sep-05 8:39 
Thanks for all the suggestions. Now another question.
What data type should be used for numbers > long?

The above examples work great for 10_P_4 but I'm getting divide by zero's for 100_P_10.

I belive it's because 100! > long.

using this routine -----

long x = 1;
for(long i = 2; i <=n; ++i)
x *= i;

Debug info ----
n=100
i=2;x=2
i=3;x=6
i=4;x=24
i=5;x=120
i=6;x=720
i=7;x=5040
i=8;x=40320
i=9;x=362880
i=10;x=3628800
i=11;x=39916800
i=12;x=479001600
i=13;x=6227020800
i=14;x=87178291200
i=15;x=1307674368000
i=16;x=20922789888000
i=17;x=355687428096000
i=18;x=6402373705728000
i=19;x=121645100408832000
i=20;x=2432902008176640000
i=21;x=-4249290049419214848
i=22;x=-1250660718674968576
i=23;x=8128291617894825984
i=24;x=-7835185981329244160
i=25;x=7034535277573963776
i=26;x=-1569523520172457984
i=27;x=-5483646897237262336
i=28;x=-5968160532966932480
i=29;x=-7055958792655077376
i=30;x=-8764578968847253504
i=31;x=4999213071378415616
i=32;x=-6045878379276664832
i=33;x=3400198294675128320
i=34;x=4926277576697053184
i=35;x=6399018521010896896
i=36;x=9003737871877668864
i=37;x=1096907932701818880
i=38;x=4789013295250014208
i=39;x=2304077777655037952
i=40;x=-70609262346240000
i=41;x=-2894979756195840000
i=42;x=7538058755741581312
i=43;x=-7904866829883932672
i=44;x=2673996885588443136
i=45;x=-8797348664486920192
i=46;x=1150331055211806720
i=47;x=-1274672626173739008
i=48;x=-5844053835210817536
i=49;x=8789267254022766592
i=50;x=-3258495067890909184
i=51;x=-162551799050403840
i=52;x=-8452693550620999680
i=53;x=-5270900413883744256
i=54;x=-7927461244078915584
i=55;x=6711489344688881664
i=56;x=6908521828386340864
i=57;x=6404118670120845312
i=58;x=2504001392817995776
i=59;x=162129586585337856
i=60;x=-8718968878589280256
i=61;x=3098476543630901248
i=62;x=7638104968020361216
i=63;x=1585267068834414592
i=64;x=-9223372036854775808
i=65;x=-9223372036854775808
i=66;x=0
i=67;x=0
i=68;x=0
i=69;x=0
i=70;x=0
i=71;x=0
i=72;x=0
i=73;x=0
i=74;x=0
i=75;x=0
i=76;x=0
i=77;x=0
i=78;x=0
i=79;x=0
i=80;x=0
i=81;x=0
i=82;x=0
i=83;x=0
i=84;x=0
i=85;x=0
i=86;x=0
i=87;x=0
i=88;x=0
i=89;x=0
i=90;x=0
i=91;x=0
i=92;x=0
i=93;x=0
i=94;x=0
i=95;x=0
i=96;x=0
i=97;x=0
i=98;x=0
i=99;x=0
i=100;x=0



-- modified at 14:41 Saturday 10th September, 2005
GeneralRe: Math troubles Pin
leppie10-Sep-05 10:04
leppie10-Sep-05 10:04 
QuestionRowCount of a DataTable Pin
surfman199-Sep-05 14:14
surfman199-Sep-05 14:14 
AnswerRe: RowCount of a DataTable Pin
Expert Coming9-Sep-05 14:18
Expert Coming9-Sep-05 14:18 
GeneralRe: RowCount of a DataTable Pin
Andy Brummer9-Sep-05 14:49
sitebuilderAndy Brummer9-Sep-05 14:49 
AnswerRe: RowCount of a DataTable Pin
Gary Thom9-Sep-05 14:19
Gary Thom9-Sep-05 14:19 
AnswerRe: RowCount of a DataTable Pin
surfman199-Sep-05 14:20
surfman199-Sep-05 14:20 
QuestionDeserialize Error Pin
dicas9-Sep-05 13:50
dicas9-Sep-05 13:50 
AnswerRe: Deserialize Error Pin
Guffa9-Sep-05 13:56
Guffa9-Sep-05 13:56 
GeneralRe: Deserialize Error Pin
Daniel132410-Sep-05 2:21
Daniel132410-Sep-05 2:21 
QuestionHow to make DebugView see my program Pin
Susan Hernandez9-Sep-05 12:37
Susan Hernandez9-Sep-05 12:37 
AnswerRe: How to make DebugView see my program Pin
Andy Brummer9-Sep-05 15:01
sitebuilderAndy Brummer9-Sep-05 15:01 
GeneralRe: How to make DebugView see my program Pin
Susan Hernandez12-Sep-05 6:00
Susan Hernandez12-Sep-05 6:00 
AnswerRe: How to make DebugView see my program Pin
S. Senthil Kumar9-Sep-05 22:27
S. Senthil Kumar9-Sep-05 22:27 
GeneralRe: How to make DebugView see my program Pin
Susan Hernandez12-Sep-05 6:06
Susan Hernandez12-Sep-05 6:06 
QuestionData Table Error Pin
Expert Coming9-Sep-05 11:48
Expert Coming9-Sep-05 11:48 
AnswerRe: Data Table Error Pin
Andy Brummer9-Sep-05 12:26
sitebuilderAndy Brummer9-Sep-05 12:26 
GeneralRe: Data Table Error Pin
Expert Coming9-Sep-05 12:41
Expert Coming9-Sep-05 12:41 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.