# Html Assignment

1:-what are inline elements and block elements in HTML and the difference between them? Name a few inline elements and block elements.

Ans: -Inline elements:- A line break is not used to begin an inline element.

An Inline element only uses the space that is required. An Inline element can not contain a block-level element.

Block-level element:-

A Block-level element always begins on a new line and browsers add a margin (a space) before and after the element by default. A Block-level element always occupies the entire available width.

Examples of Block level elements:- &lt;p&gt;,&lt;ol&gt;,&lt;ul&gt;,&lt;dl&gt;,&lt;div&gt; etc.

Examples of Block level elements:-&lt;a&gt;,&lt;em&gt;,&lt;i&gt;,&lt;span&gt;,&lt;strong&gt; etc.

  

2:- how to work with images in  HTML and explain in detail &lt;img/&gt; tag important attributes?

Ans:- The HTML&lt;img&gt; tag is used to embed an image in a web page. Images are a common element of web design. the image tag has two attributes that are 1-src:- it is used to specify the path of images.

2:-alt:-it is used to specify the alternative text for the images.

  

3;-how to create a LIST in HTML?

Ans:- we can create a list by using &lt;ol&gt; tag. Each item starts with the &lt;li&gt; tag.

&lt;ol&gt; stands for an ordered list.

 Example;-

&lt;ol&gt;

&lt;li&gt;Kumar&lt;/li&gt;

&lt;li&gt;Sunil&lt;/li&gt;

&lt;/ol&gt;

An unordered list starts with   &lt;ul&gt; tag. Each item starts with the &lt;li&gt; tag.

 Example;-

&lt;ul&gt;

&lt;li&gt;Kumar&lt;/li&gt;

&lt;li&gt;Sunil&lt;/li&gt;

&lt;/ul&gt;

It gives the data in bullet point form.

Html also supports Description lists.

The &lt;dl&gt; tag defines the description list.

  
  

4:-how do interlink web pages and navigate people to another website?

Ans:- Linking in HTML is done with the anchor tag, the&lt;A&gt; tag. The “A”  in the tag is followed by “HREF”.

For example:-

&lt;A  HREF=”[https://google.com/”](https://google.com/”)\&gt; Google Search Engine&lt;/A&gt;
