logo

Crowdly

Browser

Add to Chrome

Objektumorientált programozás

Looking for Objektumorientált programozás test answers and solutions? Browse our comprehensive collection of verified answers for Objektumorientált programozás at moodle.ms.sapientia.ro.

Get instant access to accurate answers and detailed explanations for your course questions. Our community-driven platform helps students succeed!

Hogyan érhetünk el egy static metódust kívülről?

0%
0%
0%
View this question
Milyen függvénnyel kérdezzük le egy ArrayList méretét?
0%
0%
View this question
Mi lesz a következő kódrészlet eredménye?

int array[ ] = new int[ 3 ];for( int a : array ){ System.out.print(a);}
View this question

Adott a következő osztály. A megadott kódrészletekből válassza ki azokat, amelyek hibamentesen lefutnak.

import java.util.ArrayList;
public class Delete {

public static void main(String args[]) {

ArrayList<String> names = new ArrayList<String>();

names.add("Fulop Peter");

names.add("Biro Emese");

names.add("Kukta Piroska");

names.add("Szanto Zoltan");

names.add("Bodo Barna");

names.add("Egyed Barna");

}

}

0%
View this question

Mi lesz a kimenet az alábbi kód esetén?

ArrayList<Integer> list = new ArrayList<>();

list.add(10);

list.add(20);

list.add(30);

System.out.println(list.get(1));

0%
0%
0%
0%
View this question
Mi lesz a következő kódrészlet eredménye?

1.  int array[ ][ ] = { {1}, {1, 2}, {1, 2, 3}};2.  for( int[ ] a: array ){3.      System.out.print(a.length);4.  }
View this question

Mit ír ki a következő program?

public class Main {

public static void main(String[] args) {

int[] t1 = new int[4];

for (int i = 0; i < t1.length; ++i) {

t1[i] = 10;

}

int[] t2 = new int[2];

for (int i = 0; i < t2.length; ++i) {

t2[i] = 20;

}

t1 = t2;

for (int e : t1) {

System.out.print(e + ",");

}

}

}

0%
0%
0%
0%
View this question
Mit ír ki a következő program?

public class JavaApplication {

public static void main(String[] args) {

int x[] = new int[10];

System.out.print(x[0] + ", " + x[9] + ", ");

for (int i = 0; i < x.length; ++i) {

x[i] = i;

}

System.out.println(x[0] + ", " + x[9]);

}

}

0%
0%
0%
View this question
Milyen kifejezéssel hivatkozunk az arfolyam nevű egydimenziós tömb hosszára?

int arfolyam[];

View this question

Mi a kimenete a következő programnak?

public class JavaApplication{

public static void main(String[] args) {

int x[] = new int[ 10 ];

System.out.print( x.length +", ");

x.length = 20;

System.out.println( x.length );

}

}
0%
0%
0%
0%
View this question

Want instant access to all verified answers on moodle.ms.sapientia.ro?

Get Unlimited Answers To Exam Questions - Install Crowdly Extension Now!

Browser

Add to Chrome