Download as pdf or txt
Download as pdf or txt
You are on page 1of 3

Total No.

of Printed Pages: 3 SEM 3 BCA SE 21

2021
(March)
COMPUTERAPPLICATION
(Skill Enhancement)
(PHP Progrumming)
Course Code: ANT-SE-T2-301
Credit:2

Total Marks: 50(Th-28+Prac-124+IA-10) Time: 1/, IHours

Thefigure in the margin indicatefull marks


for the questions

1. Choose the correct answer: 1x55


(a) PHP files have a default file extension of
() html (ii).xml (ji) php (iv)ph
(b) Which version of PHP introduced Try/catch Exception?
() PHP 4 (i) PHP 5

(iil)PHP 6 (iv) PHP 5 and later

Contd.
(c) How should we add a single line comment in
our PHP code ?
(i) iii) #
(iv) /*
(d Which of the below symbols is a
newline character?
) r
i)n (iin) /n
(iv)/r
(e) PHP's numerically indexed
position array begin with

() 1 (i) 2
(iv)-1
2.
2. Answer the following:
2x3-6
(a) Can we run PHP from HTML file?
If yes, how ?
(b) Differences between GET and POST methods?
(c) What these tags specifyin PHP <? PHP and 2>2

3. Write about the following built-in functions


(any three): 2x3=6
) Trim)0
(i) Strlen0
(ii) Strchar()
(iv) Strtoupper)
(v) Join0

Contd....3
A4. Explain anythree data types used in PHP 3

5 Answer any two ofthefollowing: 2x4-8

(a) Write PHP function that checks if a string is in lowercase.


is
(b) Write PHP function that checks ifa given numbér prime
or

not.
function that print first even numbers.
(c)
() Write PHP
(d) Write PHP function that adds firstn numbers.

====O=

You might also like