Novell Previous Years Solved Sample Placement Papers
-
What will be the output of the following program?
A. Welcome to the javaTpoint.com
B. welcome to the javaTpoint.com
C. Welcome To The JavaTpoint.com Answer: Option C
D. Welcome to the JavaTpoint.com
- Solution: The ucwords() is an in-built function of PHP, which is used to convert the first character of each word to uppercase in a string. It takes a string as an input and converts the first character of each word of the string to uppercase. The other characters of the string remain the same.
-
What will be the output of the following program?
A. 2015 Answer: Option A
B. 2020
C. 1515
D. 0
- Solution: In the given program, first the show() function is called, and the variable $a is initialized to 20, and 20 is printed on the screen. Later, the global variable $a is initialized to 15, and the value 15 is printed on the screen. So the output of the above program will be 2015.
-
What will be the output of the following program?
A. Hii everyone
B. Hello World Answer: Option B
C. Hello World Hii everyone
D. None of the above
- Solution: The precedence of ++ is higher than <, so first increment happens and then comparison. But when comparison happens, both OR operator condition will return false. Therefore, the if loop will not run, and the echo statement in the else block will be printed.
-
What will be the output of the following program?
A. welcome To The JavaTpoint.com Answer: Option A
B. Welcome To The JavaTpoint.com
C. Welcome To The javaTpoint.com
D. None of the above
- Solution: The lcfirst() is an in-built PHP string function. It is used to convert the first character of a string to lowercase. In other words, we can say that it makes a string's first character lowercase. It returns the converted string.
-
What will be the output of the following program?
A. HelloWorld
B. This is javaTpoint.com
C. Hello
D. HelloWorldThis is javaTpoint.com Answer: Option D
- Solution: In the given program, there is no break provided, so all cases will get executed. Given variable $a is initialized with 1, so case 1 will execute first and then case 2 and at last default will be executed.
-
What will be the output of the following program?
A. Welcome to the javaTpoint.com Answer: Option A
B. Wulcomu to tha juvuTpoint.com
C. Walcoma to the jeveTpoint.com
D. None of the above
- Solution: The strtr() is an in-built function of PHP, which is used to replace a substring inside the other string. It provides the facility to change the particular word in a string. The strtr() function translates characters or replaces the substrings. It is a case-sensitive function.