Search
Search titles only
By:
Search titles only
By:
Log in
Register
Search
Search titles only
By:
Search titles only
By:
Menu
Install the app
Install
Forums
New posts
All threads
Latest threads
New posts
Trending threads
Trending
Search forums
What's new
New posts
New ads
New profile posts
Latest activity
Free Ads
Latest reviews
Search ads
Members
Current visitors
New profile posts
Search profile posts
Contact us
Latest ads
Toyota Vitz scp10 For Sale
Lakmal Bandara
Updated:
Today at 10:50 AM
Ad icon
Cam ෂෝ කරන්න ආස කෙල්ලෝ
vip video seller srilanka
Updated:
Today at 2:17 AM
Cam show job
vip video seller srilanka
Updated:
Today at 2:01 AM
Vip විඩීයෝ තියේ හොරෙන් රෙකෝඩ් කරපුවා
vip video seller srilanka
Updated:
Today at 1:26 AM
Kandy
Welcome all my all new pet shop Bark.lk
dilumrane
Updated:
Monday at 12:26 PM
Electronics
Vehicles
Property
Search
Reply to thread
Forums
General
ElaKiri Help
C Programmers Help Me!!!!
Get the App
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Message
<blockquote data-quote="madurax86" data-source="post: 3974650" data-attributes="member: 1293"><p>i did think that 1 is a prime when i was coding <img src="/styles/default/xenforo/smilies/default/P.gif" class="smilie" loading="lazy" alt=":P" title=":P :P" data-shortname=":P" /> it should be it is dividable by 1 and itself which we see as a common thing in all other prime numbers, its just a definition not actual math. I didnt now the definition at the time of coding and i thought of the common factor in all primes and included 1 as a prime too </p><p>The program is only made for integers not real numbers so excluding 2 and even 3 would not result in a wrong output because isprime is assigned true at the beginning and if some number was lesser than 2 then it would do nothing, the while would not execute and the answer will be delivered through a shortcut you can put i>3 also it wont result in wrong outputs it just uses the shortcut for those numbers that we have provided. </p><p>If you are interested on programming, check out the calc i made its in my blog i made it with a friend of mine. <img src="/styles/default/xenforo/smilies/default/D.gif" class="smilie" loading="lazy" alt=":D" title="Big grin :D" data-shortname=":D" /> think of the shortcuts before you start coding that might make ur prog a lot faster and that is what we all need.</p><p>\/</p><p>\/</p><p>\/</p></blockquote><p></p>
[QUOTE="madurax86, post: 3974650, member: 1293"] i did think that 1 is a prime when i was coding :P it should be it is dividable by 1 and itself which we see as a common thing in all other prime numbers, its just a definition not actual math. I didnt now the definition at the time of coding and i thought of the common factor in all primes and included 1 as a prime too The program is only made for integers not real numbers so excluding 2 and even 3 would not result in a wrong output because isprime is assigned true at the beginning and if some number was lesser than 2 then it would do nothing, the while would not execute and the answer will be delivered through a shortcut you can put i>3 also it wont result in wrong outputs it just uses the shortcut for those numbers that we have provided. If you are interested on programming, check out the calc i made its in my blog i made it with a friend of mine. :D think of the shortcuts before you start coding that might make ur prog a lot faster and that is what we all need. \/ \/ \/ [/QUOTE]
Insert quotes…
Verification
Dahaya deken beduwama keeyada?
Post reply
Top
Bottom