Title:      
Web-Link: http://www.arabteam2000-forum.com/index.php?showtopic=125072
Description: Get Prime Numbers
Department: Visual Basic forum
Develop Using: Microsoft Visual Basic 6.0
Assistant Tool(s): 
Version: 1.00
Last update: 27 April 2007
Date: 27 April 2007
Time Zone: (GMT + 02:00) Cairo
Author: Eng. Usama El-Mokadem: musama@hotmail.com

Topic(125072) [Apr 27 2007, 02:52 PM]: By AliveMyth: http://www.arabteam2000-forum.com/index.php?showuser=111061
=======
-----BEGIN TOPIC-----
              

              
      

 :
       0  100
         

          

   
-----END TOPIC-----

Solution:
=======
-----BEGIN SOLUTION-----
Private Function IsPrime(n As Long) As Boolean
    Dim i As Long
    
    For i = 2 To n / 2
        If (n Mod i) = 0 Then
            IsPrime = False
            Exit Function
        End If
    Next i

    IsPrime = True
End Function
  
-----END SOLUTION-----

Attachments:
============
Prime.zip
The (Attached) Solution Suggested By Eng. Usama El-Mokadem: http://www.arabteam2000-forum.com/index.php?showuser=98027

CONTACT INFORMATION:
=======================
  Eng. Usama El-Mokadem
  Email: musama@hotmail.com
  Web: http://musama.tripod.com
  Mobile: 0020 10 1289308
  Egypt