12th Information Technology Unit Test 1 2024 25 Question Bank With

You might also like

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

Question Bank with Answer Key 2024-25

Unit Test 1
Subject: - Information Technology Class:12th
_______________________________________________________________

Q.1 Fill in the blanks:

1) <input type=”__color___”> defines a color picker.


2) __Positioning_____ is used with elements that overlap with each other.
3) The ___meta___ tag describes aspects of contents of a web page.
4) __Selector_____ indicates the HTML element you want to style.
5) __Inline____ CSS is used to apply CSS on a single line of element.
6) The __Background-color____ property is used to set background color in your
webpage
7) An __ID___ is always unique within the page so it is unique element.
8)The __Universal____ selector is used as a wildcard character.
9) __Display:Block_____ property is used to display an element as an block
element.
10) __Ordered___ list is also called as numbered list.
----------------------------------------------------------------------------------------------------
Q.2 State True of False:

1) Charset is used for character encoding declaration.


- True
2).cs is the extension of CSS file
- False
3)<input type=”email”> defines a field for entering number.
- False
4) Required attribute specifies than an input field must be filled out
- True
5) <meta charset =”UTF-8”>is for Chinese characters.
- False
6)CSS describes how HTML elements are to be displayed on screen.
- True
7) Inline CSS is used to apply CSS in multiple lines or elements.
- False
8) Background-color property is used to set the background color in your
web page.
- True
9) External CSS uses <link> tag.
- True
10) .abc {color:blue} is example of class selector.
- True
11) There are four types of positioning in CSS.
- True
12) Float : none is the default property.
- True
----------------------------------------------------------------------------------------------------
Q.3 Multiple Choice Question (select one)

1) ____ character is used to create id in CSS


a) % b) $ c) @ d) #

2) _____ is currently used because it supports mobile technology


a) DOM b) HTTP c) HTML5 d) FTP

3) The _____ tag is used to create a form


a) <input> b) <text area> c) <select> d) <form>

4)<input type=”____”>defines a text field for entering a search string


a) File b) Range c) Search d) Tel

5)The _____ attributes of <input> tag specifies a regular expression to


check the input values.
a) Required b) Multiple c) Pattern d) Max

6) The _____ attributes of <input> tag specifies that the input field should
automatically got focus when the page loaded.
a) autocomplete b) multiple c) autofocus d) required

7) The _____ attribute of <input> tag is used to apply CSS style to the
individual input element.
a) Relative b) Class c) ID d) Absolute

8)Sangeeta wants to collect mobile number of his friend in a specific


format. Which of the following correct attribute of “tell”she should use
while designing a form?
a) <input type=”tel” pattern=”[0-9] {2} - [0-9] {10}”>
b) <input type=”tel” format=”[0-9] {2} - [0-9] {10}”>
c) <input type=”tel” max=”[0-9] {2} - [0-9] {10}”>
d) <input type=”tel” multiple=”[0-9] {2} - [0-9] {10}”>

9) Each declaration contains a property name and value, separated by_____


a) Colon b) Comma c) Semicolon d) Period

10)____ are assigned to CSS properties.


a) Methods b) Values c) Selector d) Property

11)Example of Inline CSS is____


a) <body background-color : red>
b) <body style =”background-color : red”>
c) <body class =”background-color : red”>
d) <body id =”background-color : red”>
----------------------------------------------------------------------------------------------------
Q. 4 Answer the following: (any three)

1) Explain the CSS with syntax?


Ans :1) A CSS style sheet consists of a set of rules that are interpreted by the web
browser and then applied to the corresponding elements such as paragraphs,
headings, etc. in the document.
2) A CSS rule have two main parts, a selector and one or more declarations:

3) The selector specifies which element or elements in the HTML page the CSS
rule applies to. Whereas, the declarations within the block determines how the
elements are formatted on a webpage.
4) Each declaration consists of a property and a value separated by a colon (:) and
ending with a semicolon (;), and the declaration groups are surrounded by curly
----------------------------------------------------------------------------------------------------
2) Explain External Style Sheet?
Ans: 1)External CSS is used when we want to make changes on multiple
pages.
2) It uses <link> tag which is placed inside head section.
----------------------------------------------------------------------------------------------------
3) Explain Inline Style Sheet with example?
Ans: 1)Inline style sheet uses the style attribute in the HTML tag.
2)Inline CSS is used to apply CSS on a single line or element.
3)For example <p style="color:red">XII Information Technology</p>
----------------------------------------------------------------------------------------------------
4) Explain Float property?
Ans: Float is a CSS property written in CSS file. It defines the flow of the
content.
Following are the types of floating properties:
1. float: left: this keeps the element float on left side of the container
2. float: right: this keeps the element float on right side of container
3. float: none: this is default property i.e. this shows the element as it is
----------------------------------------------------------------------------------------------------
5) Explain any 2 attributes of <meta> tag?
i) Attribute : Name
Value : The value of the name attribute can be related to any of the following-
i) Author ii) Description iii) Keywords iv) copyright e.g.
Description : Specifies the Name of the metadata like the author, keywords or
description.
ii) Attribute: Content
Value : It can have any textual matter related to the name as in eg.
i. <meta name = "author" content = "Balbharti">
ii. <meta name = "description" content = "Advance web de- signing">
iii. <meta name = "keywords" content = "html5, learn html5, list in html 5">
Description : Here content of author is balbharati. Here the value for content
attribute specifies name of the topic advance web designing. Here the values for
content attribute are given as keywords like html5 , learn html5 etc.
iii) Attribute: Charset
Value : UTF-8, Big5 e.g
<meta charset="UTF-8">
<meta charset="Big5">
Description : Specifies the character encoding used by the document, This is
called a character encoding declaration. UTF-8 For Indian characters Big5 – for
Chinese characters
iv) Attribute: http-equiv
Value : refresh, set-cookie, content-type, expires,
e.g. <meta http-
equiv="refresh"content="5">
<meta http-equiv="set-cookies">
<meta http-equiv="content- type"content="text/ html"charset="Big5">
<meta http-equiv="expires" content="userid=pqr;
expires=Wednesday, 8-feb-2018 23:59:59 GMT;">
Description : Used for http response message headers. Here the page will get
refresh after every 5 seconds. The browser sends the cookies back to the server.
Specifies the character encoding for the document Here page session will get
expire at specified date and time.
----------------------------------------------------------------------------------------------------
6) Write any 3 <input > elements?
7) Write any 2 properties of CSS with example?

Ans:
8) Explain CSS Class Selector?
Ans: The class selectors can be used to select any HTML element that has
a class attribute. All the elements having that class will be formatted
according to the defined rule. The class selector is defined with a period
sign (.) immediately followed by the class value. Class name should not
start with a number.

9) Expalin Display Property?


Ans: Float is a CSS property written in CSS file. It defines the flow of the
content. Following are the types of floating properties :

1. float: left :- this keeps the element float on left side of the container

2. float: right :- this keeps the element float on right side of container

3. float: none :- this is default property i.e. this shows the element as it is.

Q. 5 Write HTML code for the following (any one) 4 marks

1) Write Html code for the following

Ans:
<!DOCTYPE html>
<html>
<head><title>Unordered List</title></head>
<body>
<ul>
<li>Basics of IT</li>
<li>HTML 5</li>
<li>Postgre SQL</li>
</ul>
</body>
</html>
----------------------------------------------------------------------------------------------------
2) Write Html5 code with css as follow:
i) To create form accept name,age,email address, from the user
ii)Create a sumbit button to send the data
iii) The heading of the form should have a background colour and different font
style:
Ans:
<!DOCTYPE html>
<html>
<head>
<title>User Registration Form</title>
<style>
h1{background-color:green; font-style:italic;}
</style>
</head>
<body>
<h1 align=”center”> User Registration Form </h1>
<form>
Enter Name :
<input type=”text” name=”t1”><br><br>
Enter Age :
<input type=”number” name=”age”><br><br>
Enter Email Id :
<input type=”email” name=”email”><br><br>
<input type=”submit” name=”b1” value=”Submit”><br><br>
</form>
</body>
</html>
----------------------------------------------------------------------------------------------------
4) Write Html5 code with CSS as follows:
i)Create ordered list with name of Tourist Cities
ii)The heading name should be large in size as ” Tourist Cities ”
ii)Create section for the orderlist
iii)Use Ilnlie style sheet the background colour of the section should be yellow.
Ans:
<!DOCTYPE html>
<html>
<head><title>Onordered List</title></head>
<body>
<section style=”background-color:yellow;”>
<h1> Tourist Cities </h1>
<ol>
<li>Pune</li>
<li>Banglore</li>
<li>Delhi </li>
</ol>
</section>
</body>
</html>
----------------------------------------------------------------------------------------------------

You might also like