Programming, website development forum Get latest updates by RSS Follow TechnicalTalk on Twitter Follow TechnicalTalk on Facebook 
HomeSearchRecent PostsLoginRegisterContact Us

Username  
Password    
  Forgot your password?  

Pages: [1]   Go Down
 
  Email this topic  |  Print
0 Members and 1 Guest are viewing this topic.

"variable arrayB & arrayA has not been initialized" how can i fix this? here's m

 
webmaster forum
anbu2020  Offline
Activity
0%
 
New Poster
Posts: 5
Topics: 3
August 17, 2010, 05:02:16 AM



Help me i have an error in my java code

import java. util. Scanner; //bubble sorting


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

int n;
int u;
boolean Execute = true;
int bub = 0;
int i = 0;
int x = 1;
int evenctr, oddctr;


______________________
 Income Protection Insurance| Life Insurance Quotes
 
webmaster forum
polas  Offline
Activity
33.33%
 
Code Guru
Gender: Male
Posts: 1399
Topics: 85
WWW
August 19, 2010, 11:39:08 AM

I don't see any variable of that name in your code snippet, let alone a variable. If you initalise them inside a conditional (or try/catch) you will get this, initialise them to null initially.

Mesham Type Oriented Parallel Programming Language, Free online technical support
 
webmaster forum
kevisa23  Offline
Activity
0%
 
New Poster
Posts: 7
Topics: 1
September 09, 2010, 04:40:49 AM

I don't see variables  arrayB and arrayA in ur code.  here are examples of  declaring  and initialing  arrays    example :
 int [] a = { 1,2,3}
int [] a = new int [2]
a[0]= 1
 
 
  Email this topic  |  Print
Pages: [1]   Go Up
 
Jump to:  



Powered by SMF 1.1.15 | SMF © 2011, Simple Machines


Google visited last this page January 25, 2012, 09:08:19 PM