8 Replies - 26645 Views - Last Post: 07 December 2009 - 12:53 AM Rate Topic: -----

#1 Jamesazim  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 1
  • Joined: 20-February 08

a program for counting, displaying even and odd numbers

Post icon  Posted 20 February 2008 - 04:12 AM

help me
Is This A Good Question/Topic? 0
  • +

Replies To: a program for counting, displaying even and odd numbers

#2 AmitTheInfinity  Icon User is offline

  • C Surfing ∞
  • member icon

Reputation: 119
  • View blog
  • Posts: 1,565
  • Joined: 25-January 07

Re: a program for counting, displaying even and odd numbers

Posted 20 February 2008 - 05:14 AM

View PostJamesazim, on 20 Feb, 2008 - 04:42 PM, said:

help me



at least 10th post asking for ready made code today [that's what I observed, count may be more than this]. Is that assignment submission date for schools approaching? :crazy:


We are here to help you friends, not to do the homework for you. Grow up and do your things yourself.

[are you going to ask us to f*** your girl for the first time, just because you are new to it? :blink: ]

This post has been edited by PsychoCoder: 20 February 2008 - 05:42 AM

Was This Post Helpful? 0
  • +
  • -

#3 Jayman  Icon User is offline

  • Student of Life
  • member icon

Reputation: 418
  • View blog
  • Posts: 9,532
  • Joined: 26-December 05

Re: a program for counting, displaying even and odd numbers

Posted 20 February 2008 - 12:22 PM

Dream.In.Code has a policy by which we prefer to see a good faith effort on your part before providing source code for homework assignments. Please post the code you have written in an effort to resolve the problem, and our members would be happy to provide some guidance. Be sure to include a description of any errors you are encountering as well.

Post your code like this: :code:

Thanks.
Was This Post Helpful? 0
  • +
  • -

#4 LookNAO  Icon User is offline

  • D.I.C Head

Reputation: 2
  • View blog
  • Posts: 66
  • Joined: 28-December 07

Re: a program for counting, displaying even and odd numbers

Posted 22 February 2008 - 07:05 AM

Count from 1 to 100
If it's even print in column 1
If it's odd print it in column 2

no code, no help.
Was This Post Helpful? 0
  • +
  • -

#5 KG87  Icon User is offline

  • D.I.C Head

Reputation: 2
  • View blog
  • Posts: 52
  • Joined: 25-September 07

Re: a program for counting, displaying even and odd numbers

Posted 22 February 2008 - 08:10 AM

I agree with the others, though it can be troublesome working things out on your own

Here's a start for you


for i = 1 to 100

[i]insert code here[/i]

next i




lol have fun :blink:
Was This Post Helpful? 0
  • +
  • -

#6 LookNAO  Icon User is offline

  • D.I.C Head

Reputation: 2
  • View blog
  • Posts: 66
  • Joined: 28-December 07

Re: a program for counting, displaying even and odd numbers

Posted 25 February 2008 - 10:57 AM

another big hint...

if int(i/2)=i/2 then

I am even... :-)

end if
Was This Post Helpful? 0
  • +
  • -

#7 Derek1990  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 1
  • Joined: 05-April 09

Re: a program for counting, displaying even and odd numbers

Posted 05 April 2009 - 08:28 PM

View PostLookNAO, on 25 Feb, 2008 - 09:57 AM, said:

another big hint...

if int(i/2)=i/2 then

I am even... :-)

end if

ummm....i have a problem i was never formaly trained on how to use a timer, and i tried to get it i just cant, well i kinda did, i got a countdown timer to work but not just a counting one, you see i need my program to just count like 1...2...3...4...etc but i cant get it to work.....it always needs a damn maxtime variable, here is what i have so far any help would be greatly appriciated thanks, "lblTime.Caption = Format((Int((M - C) / 60)), "00") & ":" & Format(((M - C) Mod 60), "00")
Was This Post Helpful? 0
  • +
  • -

#8 Nikhil_07n  Icon User is offline

  • The cheese stands alone..
  • member icon

Reputation: 49
  • View blog
  • Posts: 2,489
  • Joined: 09-January 09

Re: a program for counting, displaying even and odd numbers

Posted 05 April 2009 - 10:09 PM

View PostAmitTheInfinity, on 20 Feb, 2008 - 04:44 PM, said:

at least 10th post asking for ready made code today [that's what I observed, count may be more than this]. Is that assignment submission date for schools approaching? :crazy:


No, atleast in our country, It has gone..
Was This Post Helpful? 0
  • +
  • -

#9 redseangel  Icon User is offline

  • New D.I.C Head

Reputation: 1
  • View blog
  • Posts: 8
  • Joined: 29-November 08

Re: a program for counting, displaying even and odd numbers

Posted 07 December 2009 - 12:53 AM

dim i as integer
dim sum as integer


sum=0
for i = 1 to 100
{

if (i mod 2 == 0) then
{

sum = sum + i


}
end if

next i
}

msgbox "the sum of all even numbers are:" + sum


you cud try dis..hope it will help you :D
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1