Welcome to the Java Programming Forums

The professional, friendly Java community. 21,500 members and growing!

The Java Programming Forums are a community of Java programmers from all around the World. Our members have a wide range of skills and they all have one thing in common: A passion to learn and code Java. We invite beginner Java programmers right through to Java professionals to post here and share your knowledge. Become a part of the community, help others, expand your knowledge of Java and enjoy talking with like minded people. Registration is quick and best of all free. We look forward to meeting you.


Members have full access to the forums. Advertisements are removed for registered users.

Results 1 to 2 of 2

Thread: As a self-studying student, I need moderators to mark assignment.

  1. #1
    Junior Member
    Join Date
    Nov 2012
    Thanked 0 Times in 0 Posts

    Question As a self-studying student, I need moderators to mark assignment.

    Que: A goal post number is define as follows:
    品t is greater than 0,
    品t has five digits,
    品ts first and last digit are the same.
    For 11111,93229,15432,121,132323231,and -23452.
    Return 1 if its argument is a goal post number, otherwise return 0.
    The function signature is

    int isGoalPost(int []n);
      public static void main(string[] args){
    Int[][]  isGoalPost =new int{11111},{93229},{15432},{121},{132323231},{-23452}
    { string n =  isGoalPost[i];
     int  firstNum=string n[0];
      int  fifthNum=string n[4];
    int i;int j=0;
    for(i=0;i<= isGoalPost.length;i++);
    for(j=0;j<string n[i].length;j++);
    If (n==5.length && firstNum==fifthNum && n<0);
     return 1;
     else return 0;
    Last edited by LittleCat; November 16th, 2012 at 09:32 AM. Reason: The text field could not diplay part of the code

  2. #2
    Crazy Cat Lady KevinWorkman's Avatar
    Join Date
    Oct 2010
    Washington, DC
    My Mood
    Thanked 632 Times in 540 Posts

    Default Re: As a self-studying student, I need moderators to mark assignment.

    What happened when you ran the program? Does it work? Does it do what you expect?
    Useful links: How to Ask Questions the Smart Way | Use Code Tags | Java Tutorials
    Static Void Games - Play indie games, learn from game tutorials and source code, upload your own games!

Similar Threads

  1. Help regarding choosing J2EE book for studying
    By rohan22 in forum Java Servlet
    Replies: 1
    Last Post: May 1st, 2012, 02:02 AM
  2. assignment troubles polymorphism (guide for assignment included)
    By tdawg422 in forum What's Wrong With My Code?
    Replies: 1
    Last Post: October 8th, 2011, 10:01 AM
  3. Studying for a test, can't figure out my code won't work
    By coolidge in forum What's Wrong With My Code?
    Replies: 4
    Last Post: September 27th, 2011, 01:12 PM
  4. Hi this is mark
    By Mark Robin in forum Member Introductions
    Replies: 1
    Last Post: May 16th, 2011, 09:34 AM
  5. [SOLVED] First assignment, clueless student, involving coordinates and distances
    By Kerrigan in forum Java Theory & Questions
    Replies: 7
    Last Post: March 10th, 2011, 03:52 PM