0
Alien head

programming languages Online Quiz - 317

Description: programming languages Online Quiz - 317
Number of Questions: 20
Created by:
Tags: programming languages
Attempted 0/20 Correct 0 Score 0

Choose the correct option - Transformations which have only Input/Output ports

  1. Expression

  2. Router

  3. Lookup

  4. Aggregator


Correct Option: A

Which of the following is not a task in Workflow Manager

  1. Email

  2. Session

  3. Workflow

  4. Timer


Correct Option: C

Which of the following is not a character function

  1. LTRIM

  2. SUBSTR

  3. CONCAT

  4. TRUNC


Correct Option: D

Which activities below can be performed using Designer

  1. Run the Debugger, validate mappings and mapplets, import source definitions

  2. Run the debugger, create and delete folders, import source definitions

  3. Create and delete folders, view object dependencies, import source definitions

  4. Create and delete folders, create and edit mappings, create target tables


Correct Option: A

What types of data source(s) can be read with the source qualifier transformation?

  1. Relational Databases

  2. Relational Databases and flat files

  3. Relational Databases,lat files and cobol

  4. Relational Databases,lat files,cobol and certified ERP sources such as Peoplesoft and SAP R/3


Correct Option: D

Select the statement below that is false

  1. Tasks must be within Workflows in order to be executed

  2. Workflows must be within Tasks to be executed

  3. Workflow links may contain conditions

  4. A start task is default task in a Workflow


Correct Option: B

Which of the following are Informatica PowerCenter Server Components

  1. Informatica Server

  2. Repository Server

  3. Both A and B

  4. Neither A nor B


Correct Option: C

Which of the following is not a type of Workflow Task

  1. Mapping

  2. Decision

  3. Session

  4. Email


Correct Option: A

Repository Manager is used to

  1. Create user

  2. Create folders

  3. Assign privileges

  4. All of the above


Correct Option: D

What are the views available in the Workflow Monitor

  1. Task View and Gnatt Chart View

  2. Task View, Time View and Workflow View

  3. Task View, Gnatt Chart View and workflow view

  4. Gnatt View and Workflow view


Correct Option: A

Given: 10. public class Fabric 11. public enum Color { 12. RED(0xff0000), GREEN(0x00ff00), BLUE(0x0000ff); 13. private final int rgb; 14. Color( int rgb) { this.rgb = rgb; } 15. public int getRGB() { return rgb; } 16. }; 17. public static void main( String[] argv) { 18. // insert code here 19. } 20. } Which two code fragments, inserted independently at line 18, allow the Fabric class to compile? (Choose two.)

  1. Color skyColor = BLUE;

  2. Color treeColor = Color.GREEN;

  3. Color purple = new Color( 0xff00ff);

  4. if( RED.getRGB() < BLUE.getRGB() ) {}

  5. Color purple = Color.BLUE + Color.RED;

  6. if( Color.RED.ordinal() < Color.BLUE.ordinal() ) {}


Correct Option: B,F
  1. Given: 10. class One { 11. public One foo() { return this; } 12. } 13. class Two extends One { 14. public One foo() { return this; } 15. } 16. class Three extends Two { 17. // insert method here 18. } Which two methods, inserted individually, correctly complete the Three class? (Choose two.)
  1. public void foo() { }

  2. public int foo() { return 3; }

  3. public Two foo() { return this; }

  4. public One foo() { return this; }

  5. public Object foo() { return this; }


Correct Option: C,D

Given: 33. try { 34. // some code here 35. } catch (NullPointerException e1) { 36. System.out.print(”a”); 37. } catch (RuntimeException e2) { 38. System.out.print(”b”); 39. } finally { 40. System.out.print(”c”); 41. } What is the result if a NullPointerException occurs on line 34?

  1. c

  2. a

  3. ab

  4. ac

  5. bc

  6. abc


Correct Option: D

Click the Exhibit button. 1. public class A { 2. public void method1() { 3. B b=new B(); 4. b.method2(); 5. // more code here 6. } 7. } 1. public class B { 2. public void method2() { 3.C c=new C(); 4. c.method3(); 5. // more code here 6. } 7. } 1. public class C { 2. public void method3() { 3. // more code here 4. } 5. } Given: 25. try { 26. A a=new A(); 27. a.method1(); 28. } catch (Exception e) { 29. System.out.print(”an error occurred”); 30. } Which two are true if a NullPointerException is thrown on line 3 of class C? (Choose two.)

  1. The application will crash.

  2. The code on line 29 will be executed.

  3. The code on line 5 of class A will execute.

  4. The code on line 5 of class B will execute.

  5. The exception will be propagated back to line 27.


Correct Option: B,E

Given: 1. public class TestString3 { 2. public static void main(String[] args) { 3. // insert code here 5. System.out.println(s); 6. } 7. } Which two code fragments, inserted independently at line 3, generate the output 4247? (Choose two.) A. String s = “123456789”; s = (s-”123”).replace(1,3,”24”) - “89”; B. StringBuffer s = new StringBuffer(”123456789”); s.delete(0,3).replace( 1,3, “24”).delete(4,6); C. StringBuffer s = new StringBuffer(”123456789”); s.substring(3,6).delete( 1 ,3).insert( 1, “24”); D. StringBuilder s = new StringBuilder(”123456789”); s.substring(3,6).delete( 1 ,2).insert( 1, “24”); E. StringBuilder s = new StringBuilder(”123456789”); s.delete(0,3).delete( 1 ,3).delete(2,5).insert( 1, “24”);

  1. A

  2. B

  3. C

  4. D

  5. E


Correct Option: B,E

Given: 1. public class Threads2 implements Runnable { 2. 3. public void nun() { 4. System.out.println(”run.”); 5. throw new RuntimeException(”Problem”); 6. } 7. public static void main(String[] args) { 8. Thread t = new Thread(new Threads2()); 9. t.start(); 10. System.out.println(”End of method.”); 11. } 12. } Which two can be results? (Choose two.) A. java.lang.RuntimeException: Problem B. run. java.lang.RuntimeException: Problem C. End of method. java.lang.RuntimeException: Problem D. End of method. run. java.lang.RuntimeException: Problem E. run. java.lang.RuntimeException: Problem End of method.

  1. A

  2. B

  3. C

  4. D

  5. E


Correct Option: D,E

Click the Exhibit button. 10. class Inner { 11. private int x; 12. public void setX( int x) { this.x = x; } 13. public int getX() { return x; } 14. } 15. 16. class Outer { 17. private Inner y; 18. public void setY( Inner y) { this.y = y; } 19. public Inner getY() { return y; } 20. } 21. 22. public class Gamma { 23. public static void main( String[] args) { 24. Outer o = new Outer(); 25. Inner i = new Inner(); 26.int n=10; 27. i.setX(n); 28. o.setY(i); 29. // insert code here 30. System.out.println( o.getY().getX()); 31. } 32. } Which three code fragments, added individually at line 29, produce the output 100? (Choose three.)

  1. n = 100;

  2. i.setX( 100);

  3. o.getY().setX( 100);

  4. i = new Inner(); i.setX( 100);

  5. o.setY( i); i = new Inner(); i.setX( 100);

  6. i = new Inner(); i.setX( 100); o.setY( i);


Correct Option: B,C,F

Given: 1. package com.company.application; 2. 3. public class MainClass { 4. public static void main(String[] args) { } 5. } And MainClass exists in the /apps/com/company/application directory. Assume the CLASSPATH environment variable is set to “.“ (current directory). Which two java commands entered at the command line will run MainClass? (Choose two.) A. java MainClass if run from the /apps directory B. java com.company.application.MainClass if run from the /apps directory C. java -classpath /apps com.company.application.MainClass if run from any directory D. java -classpath . MainClass if run from the /apps/com/company/application directory E. java -classpath /apps/com/company/application:. MainClass if run from the /apps directory F. java com.company.application.MainClass if run from the /apps/com/company/application directory

  1. A

  2. B

  3. C

  4. D

  5. E

  6. F


Correct Option: B,C

class Sub extends Super{ String name; Sub(String s) { super(s); name=s; } public static void main(String args[]){ Super sup = new Super("First"); Sub sub = new Sub("Second"); System.out.println(sub.name + " " + sup.name); } } class Super{ String name; Super(String s){ name =s ; } }

  1. Error: Super(java.lang.String) in Super cannot be applied to ()

  2. First Second

  3. Second First

  4. Runtime Exception


Correct Option: C

Given: classA {} class B extends A {} class C extends A {} class D extends B {} Which three statements are true? (Choose three.)

  1. The type List is assignable to List.

  2. The type List is assignable to List>.

  3. The type List is assignable to List extends B>.

  4. The type List extends A> is assignable to List.

  5. The type List is assignable to any List reference.

  6. The type List extends B> is assignable to List extends A>.


Correct Option: B,C,F
+ View questions