Hi,
Im making a prime number checker and i need to be able to check if a number is an integer or not. Has anyone got any ideas how?
Thanks
Need C# help
Moderator: Site Moderators
-
- Posts: 44
- Joined: Fri Nov 07, 2008 9:46 pm
- Hardware configuration: WILKINS00:Intel Core2 Quad Q6600 2.4GHz 8GB PC6400/800MHz RAM Asus P5N32 Mobo Western Digital 160GB HD PNY GeForce 8800GT 256MB GDDR3
WILKINS02-Celeron D 2.8 GHz 2GB Corsair Value Select 80GB WD HD ATI RADEON HD 3450 Foxconn Mobo
WILKINS03(laptop)-Intel Core 2 Duo T7500 2.2GHz 2GB DDR2 RAM 160GB HD
RADIOSERVER-Pentium 4 3.2GHz 512mb DDR RAM 120GB HD - Contact:
-
- Site Admin
- Posts: 1288
- Joined: Fri Nov 30, 2007 9:37 am
- Location: Oxfordshire, UK
Re: Need C# help
Math.Floor(x) == x
Returns true if x is an int, false otherwise.
Google is your friend
Returns true if x is an int, false otherwise.
Google is your friend
-
- Posts: 44
- Joined: Fri Nov 07, 2008 9:46 pm
- Hardware configuration: WILKINS00:Intel Core2 Quad Q6600 2.4GHz 8GB PC6400/800MHz RAM Asus P5N32 Mobo Western Digital 160GB HD PNY GeForce 8800GT 256MB GDDR3
WILKINS02-Celeron D 2.8 GHz 2GB Corsair Value Select 80GB WD HD ATI RADEON HD 3450 Foxconn Mobo
WILKINS03(laptop)-Intel Core 2 Duo T7500 2.2GHz 2GB DDR2 RAM 160GB HD
RADIOSERVER-Pentium 4 3.2GHz 512mb DDR RAM 120GB HD - Contact:
Re: Need C# help
Thanks
i searched for ages and couldnt find what i was looking for but thanks!
i searched for ages and couldnt find what i was looking for but thanks!