944,188 Members | Top Members by Rank

Ad:
Jun 25th, 2005
0

plz help

Expand Post »
well hi
Actually i have a school assignment and i need help with it
i have 2 ques which i am not able to solve so plz help me
Q1)create a program to find wether the entered year id leap or not?
Q2)write a program to find and print maximum and minimum from one dimensional arrays?

help plz
thanks
neha
Similar Threads
Reputation Points: 10
Solved Threads: 0
Newbie Poster
coolgal_neha is offline Offline
3 posts
since Mar 2005
Jun 25th, 2005
0

Re: plz help

What have you tried so far?
Reputation Points: 11
Solved Threads: 2
Junior Poster in Training
w00dy is offline Offline
70 posts
since Jun 2005
Jun 27th, 2005
0

Re: plz help

Quote originally posted by coolgal_neha ...
well hi
Actually i have a school assignment and i need help with it
i have 2 ques which i am not able to solve so plz help me
Q1)create a program to find wether the entered year id leap or not?
Q2)write a program to find and print maximum and minimum from one dimensional arrays?

help plz
thanks
neha
Just a hint to Q1. if not(int((year/400)=year/400)) then
if(int(year/4)=year/4) then
year = leap year
you'll have to work the exact syntax.
Every 400 years (as in the year 2000, leap year is skipped to get closer to the actual solar date. -dz-

dz
Reputation Points: 10
Solved Threads: 0
Newbie Poster
dhz920 is offline Offline
1 posts
since Jun 2005
Jun 27th, 2005
1

Re: plz help

Like this?

Visual Basic 4 / 5 / 6 Syntax (Toggle Plain Text)
  1. Dim Leap As Boolean
  2.  
  3. Sub FindLeapYear
  4. Dim Year As Long
  5.  
  6. If Year/400 = Int(Year/400) Then
  7. Leap = False
  8. Exit Sub
  9. End If
  10.  
  11. If Year/4 = Int(Year/4) Then
  12. Leap = True
  13. Else
  14. Leap = False
  15. End If
  16. End Sub

always avoid complicated statements with too many brackets if you can

Give me a little more info about what you want to do in Q2
Reputation Points: 11
Solved Threads: 2
Junior Poster in Training
w00dy is offline Offline
70 posts
since Jun 2005
Jun 28th, 2005
0

Re: plz help

Yes, Please Post your code so that we can take a look at it.
Team Colleague
Reputation Points: 361
Solved Threads: 214
Taboo Programmer
Comatose is offline Offline
2,413 posts
since Dec 2004

This thread is more than three months old

No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.
Message:
Previous Thread in Visual Basic 4 / 5 / 6 Forum Timeline: Accessing network share programmatically
Next Thread in Visual Basic 4 / 5 / 6 Forum Timeline: connect with access





About Us | Contact Us | Advertise | Acceptable Use Policy
Forum Index | Build Custom RSS Feed


Follow us on Twitter


© 2011 DaniWeb® LLC