0% found this document useful (0 votes)
43 views

WT Lab

The document describes 5 Java programming experiments involving object-oriented concepts like inheritance, threads, event handling, and arithmetic/trigonometric calculations. It provides the objectives, theory, code samples, and output for programs that create a student class with inheritance, perform calculator operations in threads, handle mouse events, create a simple calculator applet, and demonstrate hyperlinks in HTML.

Uploaded by

Gagan Sharma
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
43 views

WT Lab

The document describes 5 Java programming experiments involving object-oriented concepts like inheritance, threads, event handling, and arithmetic/trigonometric calculations. It provides the objectives, theory, code samples, and output for programs that create a student class with inheritance, perform calculator operations in threads, handle mouse events, create a simple calculator applet, and demonstrate hyperlinks in HTML.

Uploaded by

Gagan Sharma
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 34

EXPERIMENT 1:

OBJECTIVE: Write a Java program for creating one base class for student personal details and inherit
those details into the sub class of student Educational details to display complete student information.
THEORY: Inheritance in Java is a mechanism in which one object acquires all the properties and
behaviors of a parent object. It is an important part of OOPs (Object Oriented programming system). The
idea behind inheritance in Java is that you can create new classes that are built upon existing classes.
When you inherit from an existing class, you can reuse methods and fields of the parent class.
Moreover, you can add new methods and fields in your current class also.

CODE:

class Personal {

String name=new String();

String fname=new String();

String add=new String();

String phno=new String();

Personal(String a,String b,String c,String d) {

name=a;

fname=b;

add=c;

phno=d;

}
void display() {

System.out.println("Name is "+name);
System.out.println("Address "+add);

System.out.println("Father's Name is "+fname);

System.out.println("Contact number "+phno);

} }

class Education extends Personal {

int roll,age;

char section;

String branch=new String();

Education(String a, String b, String c, String d, int e, int f, char g, String h) {


super(a,b,c,d);
roll=e;

age=f;
section=g;

branch=h;

void display2() {

super.display();

System.out.println("Roll Number="+roll);

System.out.println("AGE="+age);

System.out.println("SECTION="+section);
System.out.println("Branch is "+branch);

} }
class Hello {

public static void main(String args[]) {


Education e=new Education("AMAAN","NAUSHAD","JHANSI","8299512581",12,19,'A',"IT");

e.display2();

} }

OUTPUT:
EXPERIMENT 2:

OBJECTIVE: Write a Java program to create multiple threads for different calculator operations.
THEORY: Arithmetic Operators involve the mathematical operators that can be used to perform various
simple or advanced arithmetic operations on the primitive data types referred to as the operands. These
operators consist of various unary and binary operators that can be applied on a single or two operands.

OPERATOR OPERATION
+ Addition
- Subtraction
* Multiplication
/ Division
% Modulus

CODE:

import java.lang.*;

import java.util.*;

class A1 extends Thread {

int i,j;

A1(int x,int y) {

i=x;

j=y;

public void run() {


System.out.println("THREAD A:: ARITHEMATIC OPERATIONS");

System.out.println("SUM "+(i+j));
System.out.println( "DIFFERENCE "+(i-j));

System.out.println(" PRODUCT "+(i*j));

System.out.println("RATIO "+(i/j));

System.out.println("POWER "+Math.pow(i,j));

System.out.println("END OF A");

}
class B1 extends Thread {
int i;

B1(int x) {
i=x;

public void run() {

System.out.println("THREAD B:: TRIGNOMETRIC OPERATIONS");

System.out.println("SINE OF "+i+""+Math.sin(i));

System.out.println("COSINE OF "+i+""+Math.cos(i));

System.out.println("TAN OF "+i+" "+Math.tan(i));

System.out.println("SQUARE ROOT OF "+i+" "+Math.sqrt(i));


System.out.println("END OF B");

}
}

class Operate {
public static void main(String args[]) {

Scanner s=new Scanner(System.in);

System.out.println("ENTER TWO VALUES FOR ARITHEMATIC OPERATIONS");

int x=s.nextInt();

int y=s.nextInt();
System.out.println("ENTER A VALUE FOR TRIGNOMETRIC OPERATIONS");

int z=s.nextInt();

A1 a=new A1(x,y);

B1 b=new B1(z);

a.start();

b.start();

}
OUTPUT:
EXPERIMENT 3:
OBJECTIVE: Write a Java program for handling mouse events.

THEORY: An event which indicates that a mouse action occurred in a component. A mouse action is
considered to occur in a particular component if and only if the mouse cursor is over the unobscured
part of the component's bounds when the action happens. Component bounds can be obscurred by the
visible component's children or by a menu or by a top-level window. This event is used both for mouse
events (click, enter, exit) and mouse motion events (moves and drags).
This low-level event is generated by a component object for:

• Mouse Events

• a mouse button is pressed

• a mouse button is released

• a mouse button is clicked (pressed and released)

• the mouse cursor enters the unobscured part of component's geometry

• the mouse cursor exits the unobscured part of component's geometry

• Mouse Motion Events

• the mouse is moved


• the mouse is dragged

CODE:
import java.awt.*;

import java.awt.event.*;

import java.applet.*;

/*

<applet code="MouseEvents" width=300 height=100>


</applet>

*/

public class MouseEvents extends Applet

implements MouseListener, MouseMotionListener {

String msg = "";

int mouseX = 0, mouseY = 0; // coordinates of mouse


public void init() {
addMouseListener(this);

addMouseMotionListener(this);
}

// Handle mouse clicked.

public void mouseClicked(MouseEvent me) {

// save coordinates

mouseX = 0;

mouseY = 10;

msg = "Mouse clicked.";

repaint();
}

// Handle mouse entered.


public void mouseEntered(MouseEvent me) {

// save coordinates
mouseX = 0;

mouseY = 10;

msg = "Mouse entered.";

repaint();

}
// Handle mouse exited.

public void mouseExited(MouseEvent me) {

// save coordinates

mouseX = 0;

mouseY = 10;

msg = "Mouse exited.";

repaint();

// Handle button pressed.


public void mousePressed(MouseEvent me) {
// save coordinates

mouseX = me.getX();
mouseY = me.getY();

msg = "Down";

repaint();

// Handle button released.

public void mouseReleased(MouseEvent me) {

// save coordinates

mouseX = me.getX();
mouseY = me.getY();

msg = "Up";
repaint();

}
// Handle mouse dragged.

public void mouseDragged(MouseEvent me) {

// save coordinates

mouseX = me.getX();

mouseY = me.getY();
msg = "*";

showStatus("Dragging mouse at " + mouseX + ", " + mouseY);

repaint();

// Handle mouse moved.

public void mouseMoved(MouseEvent me) {

// show status

showStatus("Moving mouse at " + me.getX() + ", " + me.getY());

}
// Display msg in applet window at current X,Y location.
public void paint(Graphics g) {

g.drawString(msg, mouseX, mouseY);


}

OUTPUT:
EXPERIMENT 4:
OBJECTIVE: Write a Java program that works as a simple Calculator.

THEORY: Arithmetic Operators involve the mathematical operators that can be used to perform various
simple or advanced arithmetic operations on the primitive data types referred to as the operands. These
operators consist of various unary and binary operators that can be applied on a single or two operands.

OPERATOR OPERATION
+ Addition
- Subtraction
* Multiplication
/ Division
% Modulus

CODE:
import java.awt.*;

import java.awt.event.*;

import java.applet.*;

import javax.swing.*;

import java.lang.*;

public class Calc extends JApplet implements ActionListener {

TextField t;

GridLayout g;

Panel p;

BorderLayout b1;
Button b[]=new Button[17];

String s[]={"0","1","2","3","4","5","6","7","8","9","/","%","*","+","-","=","ac"};
int x=0,y=0,r;

boolean x1=true;

String s1,s2;

char c,op='x';

public void init() {

b1=new BorderLayout();

t=new TextField();
setLayout(b1);
add(t,BorderLayout.NORTH);

p=new Panel();
g=new GridLayout(4,4);

p.setLayout(g);

add(p,BorderLayout.CENTER);

for(int i=0;i<17;i++) {

b[i]=new Button(s[i]);

p.add(b[i]);

}
public void actionPerformed(ActionEvent e) {

if(e.getSource()==b[0])
dis("0");

if(e.getSource()==b[1])
dis("1");

if(e.getSource()==b[2])

dis("2");

if(e.getSource()==b[3])

dis("3");
if(e.getSource()==b[4])

dis("4");

if(e.getSource()==b[5])

dis("5");

if(e.getSource()==b[6])

dis("6");

if(e.getSource()==b[7])

dis("7");

if(e.getSource()==b[8])
dis("8");
if(e.getSource()==b[9])

dis("9");
if(e.getSource()==b[10])

calc('/');

if(e.getSource()==b[11])

calc('%');

if(e.getSource()==b[12])

calc('*');

if(e.getSource()==b[13])

calc('+');
if(e.getSource()==b[14])

calc('-');
if(e.getSource()==b[15])

calc(op);
if(e.getSource()==b[16]) {

s1=new String();

s2=new String();

x1=true;

t.setText("0");
op='x';

public void dis(String n) {

if(x1==true) {

s1+=n;

x=Integer.parseInt(s1);

t.setText(s1);

}
else {
s2+=n;

y=Integer.parseInt(s2);
t.setText(s2);

public void calc(char c) {

if(op!='x') {

switch(op) {

case '/':r=x/y;

break;
case '%':r=x%y;

break;
case '*':r=x*y;

break;
case '+':r=x+y;

break;

case '-':r=x-y;

break;

}
s1=String.valueOf(r);

s2="0";

t.setText(s1);

op=c;

else {

t.setText("");

op=c;

x1=false;
}
}

}
/*

<applet code="Calc.class" width=500 height=1000>

</applet>

*/

OUTPUT:
EXPERIMENT 5:
OBJECTIVE: Write a HTML program for demonstrating Hyperlinks.

• Navigation from one page to another.


• Navigation within the page

THEORY: A webpage can contain various links that take you directly to other pages and even specific
parts of a given page. These links are known as hyperlinks. Hyperlinks allow visitors to navigate between
Web sites by clicking on words, phrases, and images. Thus you can create hyperlinks using text or images
available on a webpage. A link is specified using HTML tag <a>. This tag is called anchor tag and anything
between the opening <a> tag and the closing </a> tag becomes part of the link and a user can click that
part to reach to the linked document.

CODE:

<!DOCTYPE html>

<html>

<head>

<title>Hyperlink Example</title>

<base href = "https://www.tutorialspoint.com/">

</head>

<body>

<p>Click any of the following links</p>

<a href = "/html/index.htm" target = "_blank">Opens in New</a> |

<a href = "/html/index.htm" target = "_self">Opens in Self</a> |

<a href = "/html/index.htm" target = "_parent">Opens in Parent</a> |

<a href = "/html/index.htm" target = "_top">Opens in Body</a>

</body>

</html>

OUTPUT:
EXPERIMENT 6:

OBJECTIVE: Write a javascript program to validate USER LOGIN page.


THEORY: Data validation is the process of ensuring that user input is clean, correct, and useful.Typical
validation tasks are:

• has the user filled in all required fields?

• has the user entered a valid date?

• has the user entered text in a numeric field?

Most often, the purpose of data validation is to ensure correct user input.
Validation can be defined by many different methods, and deployed in many different ways. Server side
validation is performed by a web server, after input has been sent to the server. Client side validation is
performed by a web browser, before input is sent to a web server.
CODE:

<html>

<head>

<title>Javascript Login Form Validation</title>

var attempt = 3; // Variable to count number of attempts.

function validate(){

var username = document.getElementById("username").value;


var password = document.getElementById("password").value;

if ( username == "Formget" && password == "formget#123"){


alert ("Login successfully");

window.location = "success.html"; // Redirecting to other page.

return false;

else{

attempt --;// Decrementing by one.

alert("You have left "+attempt+" attempt;");

if( attempt == 0){

document.getElementById("username").disabled = true;
document.getElementById("password").disabled = true;
document.getElementById("submit").disabled = true;

return false;
}

<script src="js/login.js"></script>

</head>

<body>

<div class="container">

<div class="main">
<h2>Javascript Login Form Validation</h2>

<form id="form_id" method="post" name="myform">


<label>User Name :</label>

<input type="text" name="username" id="username"/>


<label>Password :</label>

<input type="password" name="password" id="password"/>

<input type="button" value="Login" id="submit" onclick="validate()"/>

</form>

<span><b class="note">Note : </b>For this demo use following username and password. <br/><b
class="valid">User Name : Formget<br/>Password : formget#123</b></span>

</div></div>
</body>

</html>
OUTPUT:
EXPERIMENT 7:
OBJECTIVE: Write a javascript program for validating REGISTRATION FORM.

THEORY: Data validation is the process of ensuring that user input is clean, correct, and useful.Typical
validation tasks are:

• has the user filled in all required fields?

• has the user entered a valid date?

• has the user entered text in a numeric field?

Most often, the purpose of data validation is to ensure correct user input.

Validation can be defined by many different methods, and deployed in many different ways. Server side
validation is performed by a web server, after input has been sent to the server. Client side validation is
performed by a web browser, before input is sent to a web server.

CODE:
<!DOCTYPE html>

<html lang="en"><head>

<meta charset="utf-8">

<title>JavaScript Form Validation using a sample registration form</title>

<meta name="keywords" content="example, JavaScript Form Validation, Sample registration form" />

<meta name="description" content="This document is an example of JavaScript Form Validation using a


sample registration form. " />
</head>

<body onload="document.registration.userid.focus();">

<h1>Registration Form</h1>

Use tab keys to move from one input field to the next.

<form name='registration' onSubmit="return formValidation();">


<ul>

<li><label for="userid">User id:</label></li>

<li><input type="text" name="userid" size="12" /></li>

<li><label for="passid">Password:</label></li>

<li><input type="password" name="passid" size="12" /></li>

<li><label for="username">Name:</label></li>
<li><input type="text" name="username" size="50" /></li>
<li><label for="address">Address:</label></li>

<li><input type="text" name="address" size="50" /></li>


<li><label for="country">Country:</label></li>

<li><select name="country">

<option selected="" value="Default">(Please select a country)</option>

<option value="AF">Australia</option>

<option value="AL">Canada</option>

<option value="DZ">India</option>

<option value="AS">Russia</option>

<option value="AD">USA</option>
</select></li>

<li><label for="zip">ZIP Code:</label></li>


<li><input type="text" name="zip" /></li>

<li><label for="email">Email:</label></li>
<li><input type="text" name="email" size="50" /></li>

<li><label id="gender">Sex:</label></li>

<li><input type="radio" name="msex" value="Male" /><span>Male</span></li>

<li><input type="radio" name="fsex" value="Female" /><span>Female</span></li>

<li><label>Language:</label></li>
<li><input type="checkbox" name="en" value="en" checked /><span>English</span></li>

<li><input type="checkbox" name="nonen" value="noen" /><span>Non English</span></li>

<li><label for="desc">About:</label></li>

<li><textarea name="desc" id="desc"></textarea></li>

<li><input type="submit" name="submit" value="Submit" /></li>

</ul>

</form>

function formValidation() {

var uid = document.registration.userid;


var passid = document.registration.passid;
var uname = document.registration.username;

var uadd = document.registration.address;


var ucountry = document.registration.country;

var uzip = document.registration.zip;

var uemail = document.registration.email;

var umsex = document.registration.msex;

var ufsex = document.registration.fsex;

if(userid_validation(uid,5,12)) {

if(passid_validation(passid,7,12)) {

if(allLetter(uname)) {
if(alphanumeric(uadd)) {

if(countryselect(ucountry)) {
if(allnumeric(uzip)) {

if(ValidateEmail(uemail)) {
if(validsex(umsex,ufsex)) {

}}}}}}}}

return false;

function userid_validation(uid,mx,my) {
var uid_len = uid.value.length;

if (uid_len == 0 || uid_len >= my || uid_len < mx) {

alert("User Id should not be empty / length be between "+mx+" to "+my);

uid.focus();

return false;

return true;

function passid_validation(passid,mx,my) {
var passid_len = passid.value.length;
if (passid_len == 0 ||passid_len >= my || passid_len < mx) {

alert("Password should not be empty / length be between "+mx+" to "+my);


passid.focus();

return false;

return true;

function allLetter(uname) {

var letters = /^[A-Za-z]+$/;

if(uname.value.match(letters)) {
return true;

}
else {

alert('Username must have alphabet characters only');


uname.focus();

return false;

function alphanumeric(uadd)
{ var letters = /^[0-9a-zA-Z]+$/;

if(uadd.value.match(letters))

{ return true; }

else {

alert('User address must have alphanumeric characters only');

uadd.focus();

return false;

}}

</body> </html>
OUTPUT:
EXPERIMENT 8:
OBJECTIVE: Write a program to display contents of XML file in a table using Extensible Style Sheets.

THEORY: XSLT stands for Extensible Stylesheet Language Transformation.

• XSLT is used to transform XML document from one form to another form.

• XSLT uses Xpath to perform matching of nodes to perform these transformation .

• The result of applying XSLT to XML document could be an another XML document, HTML, text or
any another document from technology perspective.
• The XSL code is written within the XML document with the extension of (.xsl).

In other words, an XSLT document is a different kind of XML document.

CODE:

<?xml version="1.0" encoding="UTF-8"?>

<?xml-stylesheet type="text/css" href="Rule.css"?>

<books>

<heading>Welcome To GeeksforGeeks </heading>


<book>

<title>Title -: Web Programming</title>


<author>Author -: Chrisbates</author>

<publisher>Publisher -: Wiley</publisher>
<edition>Edition -: 3</edition>

<price> Price -: 300</price>


</book>

<book>

<title>Title -: Internet world-wide-web</title>

<author>Author -: Ditel</author>

<publisher>Publisher -: Pearson</publisher>

<edition>Edition -: 3</edition>

<price>Price -: 400</price>
</book>
<book>

<title>Title -: Computer Networks</title>


<author>Author -: Foruouzan</author>

<publisher>Publisher -: Mc Graw Hill</publisher>

<edition>Edition -: 5</edition>

<price>Price -: 700</price>

</book>

<book>

<title>Title -: DBMS Concepts</title>

<author>Author -: Navath</author>
<publisher>Publisher -: Oxford</publisher>

<edition>Edition -: 5</edition>
<price>Price -: 600</price>

</book>
<book>

<title>Title -: Linux Programming</title>

<author>Author -: Subhitab Das</author>

<publisher>Publisher -: Oxford</publisher>

<edition>Edition -: 8</edition>
<price>Price -: 300</price>

</book>

</books>

books {

color: white;

background-color : gray;

width: 100%;

}
heading {
color: green;

font-size : 40px;
background-color : powderblue;

heading, title, author, publisher, edition, price {

display : block;

title {

font-size : 25px;

font-weight : bold;
}

OUTPUT:
EXPERIMENT 9:

OBJECTIVE: Write a servlet for session tracking.


THEORY: Servlet can be described in many ways, depending on the context.

• Servlet is a technology which is used to create a web application.

• Servlet is an API that provides many interfaces and classes including documentation.

• Servlet is an interface that must be implemented for creating any Servlet.

• Servlet is a class that extends the capabilities of the servers and responds to the incoming
requests. It can respond to any requests.
• Servlet is a web component that is deployed on the server to create a dynamic web page.

CODE:

import java.io.*;

import java.util.*;

import javax.servlet.*;

import javax.servlet.http.*;

public class GfgSession extends HttpServlet {


public void doGet(HttpServletRequest request,

HttpServletResponse response)
throws ServletException, IOException

{
HttpSession session = request.getSession(true);

Date createTime
= new Date(session.getCreationTime());

Date lastAccessTime

= new Date(session.getLastAccessedTime());

String title = "Welcome Back to geeksforgeeks";

Integer visitCount = new Integer(0);

String visitCountKey = new String("visitCount");

String userIDKey = new String("userID");


String userID = new String("GFG");
if (session.isNew()) {

title = "Welcome to GeeksForGeeks";


session.setAttribute(userIDKey, userID);

else {

visitCount = (Integer)session.getAttribute(

visitCountKey);

visitCount = visitCount + 1;

userID

= (String)session.getAttribute(userIDKey);
}

session.setAttribute(visitCountKey, visitCount);
response.setContentType("text/html");

PrintWriter out = response.getWriter();


String docType

= "<!doctype html public \"-//w3c//dtd html 4.0 "

+ "transitional//en\">\n";

out.println(

docType + "<html>\n"
+ "<head><title>" + title + "</title></head>\n"

"<body bgcolor = \"#f0f0f0\">\n"

+ "<h1 align = \"center\">" + title + "</h1>\n"

+ "<h2 align = \"center\">Gfg Session Information</h2>\n"

+ "<table border = \"1\" align = \"center\">\n"

"<tr bgcolor = \"#949494\">\n"

+ " <th>Session info</th><th>value</th>"


+ "</tr>\n"
+

"<tr>\n"
+ " <td>id</td>\n"

+ " <td>" + session.getId() + "</td>"

+ "</tr>\n"

"<tr>\n"

+ " <td>Creation Time</td>\n"

+ " <td>" + createTime + " </td>"

+ "</tr>\n"
+

"<tr>\n"
+ " <td>Time of Last Access</td>\n"

+ " <td>" + lastAccessTime + "</td>"


+ "</tr>\n"

"<tr>\n"

+ " <td>User ID</td>\n"

+ " <td>" + userID + "</td>"


+ "</tr>\n"

"<tr>\n"

+ " <td>Number of visits</td>\n"

+ " <td>" + visitCount + "</td>"

+ "</tr>\n"

+ "</table>\n"

+ "</body>"

+ "</html>"); }}
OUTPUT:
EXPERIMENT 10:

OBJECTIVE: Write a JSP that reads parameters from user login page.

THEORY: JSP technology is used to create web application just like Servlet technology. It can be thought
of as an extension to Servlet because it provides more functionality than servlet such as expression
language, JSTL, etc.

A JSP page consists of HTML tags and JSP tags. The JSP pages are easier to maintain than Servlet because
we can separate designing and development. It provides some additional features such as Expression
Language, Custom Tags, etc.

CODE:

login.html

<html>
<head>

<script type="text/javascript">
function ccheck() {

uid=document.f1.uid.value;

cpass=document.f1.cpass.value;

if(uid=="" || uid==null) {

alert("Plz. Enter Your User ID");


document.f1.uid.focus();

return false;

if(cpass=="" || cpass==null) {

alert("Plz. Enter Your Password");

document.f1.cpass.focus();
return false;
}

return true;
}

</script>

<title>Login Page in Jsp</title>

</head>

<body onload="document.f1.uid.focus()">

<h2>LOGIN PAGE IN JSP</h2>

<form id="f1" name="f1" action="doLogin.jsp" method="post" onsubmit="return ccheck()">

<table>
<tr>

<td><b>User ID</b></td>
<td><input name="uid" type="text"/></td>

</tr>
<tr>

<td><b>Password</b></td>

<td><input name="cpass" type="password"/></td>

</tr>

<tr>
<td><input type="submit" value="Submit" /> </td>

<td><input type="reset" value="Reset" /></td>

</tr>

</table>

</form>

</body>

</html>

doLogin.jsp
<%@ page import="java.sql.*" %>

<%! String cid="",pass="";Connection con; %>


<%

Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");

con=DriverManager.getConnection("jdbc:odbc:dsn1","system","pintu");

Statement stmt=con.createStatement();

ResultSet rs;

cid=request.getParameter("uid");

pass=request.getParameter("cpass");

//System.out.println("cid="+cid+" pass="+pass);
rs=stmt.executeQuery("select * from login where userid='"+cid+"' and password='"+pass+"' ");

if(rs.next()) {
session.setAttribute("scid",cid);

con.close();
response.sendRedirect("welcome.jsp");

else {

%>

<html>
<body>

<h1>Invalid UserID or Password</h1>

<jsp:include page="login.html" />

<%

%>

</body>

</html>
welcome.jsp

<%@ page import="java.sql.*" %>


<%! String scid=""; %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"


"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">

<head>

<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>


<title>Login Page</title>

</head>

<body>

<%

scid=(String)session.getAttribute("scid");

%>

<div id="welcome">
<h2><span>Welcome:::<strong><font color='Red'><%= scid %></font></strong></span></h2>

</div>
</body>

</html>
OUTPUT:

You might also like