VoyForums

VoyUser Login optional ] [ Contact Forum Admin ] [ Main index ] [ Post a new message ] [ Search | Check update time | Archives: 1 ]


[ Next Thread | Previous Thread | Next Message | Previous Message ]

Date Posted: Sun 2003-09-28 11:57:00
Author: goobergunch
Subject: Re: I'm thinking of trying to develop a simple voting algorithm in QBasic (the only language I can really work with...)
In reply to: Redeye 's message, "I'm thinking of trying to develop a simple voting algorithm in QBasic (the only language I can really work with...)" on Sat 2003-09-27 11:13:47

Sounds interesting!

In JAVA, the program would look something like this:

public class vote {
public static void main (String[] args) {

char Candidate = new char()

System.out.println ("Please choose ONE of the following candidates for the Democratic primary for the 2004 presidential election:");
System.out.println ();
System.out.println ("A. Carol Moseley Braun");
System.out.println ("B. Wesley Clark");
System.out.println ("C. Howard Dean");
System.out.println ("D. John Edwards");
System.out.println ("E. Richard Gephardt");
System.out.println ("F. Robert Graham");
System.out.println ("G. John Kerry");
System.out.println ("H. Dennis Kucinich");
System.out.println ("I. Joseph Lieberman");
System.out.println ("J. Alfred Sharpton");

//insert input code here

//call vote-stealing operations here

}
}

Of course, there's probably some way to get this to work in a GUI like the real machines...it'll probably turn out to be easier then actually inputting from the command line (JAVA input is ugly).

[ Next Thread | Previous Thread | Next Message | Previous Message ]


Replies:



VoyUser Login ] Not required to post.
Post a public reply to this message | Go post a new public message
* Notice: Posting problems? [ Click here ]
* HTML allowed in marked fields.
* Message subject (required):

* Name (required):

  Expression (Optional mood/title along with your name) Examples: (happy, sad, The Joyful, etc.) help)

  E-mail address (optional):

* Type your message here:

Choose Message Icon: [ View Emoticons ]

Notice: Copies of your message may remain on this and other systems on internet. Please be respectful.

[ Contact Forum Admin ]


Forum timezone: GMT-8
VF Version: 2.94, ConfDB:
Before posting please read our privacy policy.
VoyForums(tm) is a Free Service from Voyager Info-Systems.
Copyright © 1998-2008 Voyager Info-Systems. All Rights Reserved.