Results 1 to 3 of 3
  1. #1
    MrPosotive is offline Member
    Join Date
    Sep 2012
    Posts
    68
    Rep Power
    0

    Default Having a problem with Acii help please!

    Hey guys im trying to make a program for class that there is 4 letters and depending on which three you put in it will show you all the possible orders it could be in. for example the letters offered are a b c and d if you select a b and c then it will show you all the possible combinations of those three letters. here is my code
    Java Code:
    import java.io.*;
    
    public class Prog520a {
    	public static void main(String args[])
    	{
    		char a = 'A';
    		char b = 'B';
    		char c = 'C';
    		
    		int C = 65;
    		int B = 1;
    		int A = 1;
    		
    		char Acii = (char) C;
    		if(C != 67)
    		{
    			C++;
    			System.out.println((char) a + (char) a + Acii);
    			if(Acii == 67)
    			{
    				C = 1;
    				C++;
    				System.out.println(a + b + Acii);
    				if(Acii == 67)
    				{
    					
    				}
    			}
    		}
    	}
    }
    every time i run it it prints out one large number then nothing else, help please

  2. #2
    MrPosotive is offline Member
    Join Date
    Sep 2012
    Posts
    68
    Rep Power
    0

    Default Re: Having a problem with Acii help please!

    never mind guys i figured it out, i just had to put spaces between the a's and the Acii in the print line.

  3. #3
    DarrylBurke's Avatar
    DarrylBurke is offline Member
    Join Date
    Sep 2008
    Location
    Madgaon, Goa, India
    Posts
    11,189
    Rep Power
    19

    Default Re: Having a problem with Acii help please!

    Learn and follow the Java coding conventions. Variable names should start with a lowercase letter.
    Code Conventions for the Java Programming Language: Contents

    db
    If you're forever cleaning cobwebs, it's time to get rid of the spiders.

Similar Threads

  1. Replies: 0
    Last Post: 11-07-2012, 12:44 PM
  2. Small problem with problem with Java, C++ parse program.
    By dragstang86 in forum New To Java
    Replies: 4
    Last Post: 10-30-2011, 03:43 AM
  3. Replies: 9
    Last Post: 09-21-2010, 04:15 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •