MPT - Practical Exam Questions
MPT - Practical Exam Questions
Semester: 4
Term Dates: 15/03/2023 to 24/06/2023
Course name & Course Code: Modern Practical Tools (4340705)
Fill in the blanks in the below program code to get the below output :
<!DOCTYPE html>
<html>
<script
src="https://ajax.googleapis.com/ajax/libs/angularjs/1.6.9/angular.min.js"></scri
pt>
<body>
</div>
</body>
</html>
output: The name of my college is RCTI
VISION: To mould young and fresh minds into challenging computer professionals with ethical values and shaping them with upcoming technologies and develop the ability to
deal with real world situations with skills and innovative ideas.
Write a code to create employee service class as injector that contains employee
4 CO4 A 2
array and getEmployeeById method.
Write a code that providess an example of an Angular routing module (app-
5 routing.module.ts) that sets up routes for a student list and student details page, CO5 A 2
with a redirect to the student list as the default route?"
6 Write a code to use expression for calculating 3+2 on webpage. CO1 A 2
State the output for below code with appropriate justification.
File 1: app.component.html:
<input (keyup)="onKey(input.value)" #input>
<ng-container [ngSwitch]="componentName">
<app-fruits *ngSwitchCase="'fruits'"></app-fruits>
<app-juices *ngSwitchCase="'juices'"></app-juices>
<app-vegetables *ngSwitchCase="'vegetables'"></app-vegetables>
</ng-container>
File 2: app.component.ts
import { Component } from '@angular/core';
7 @Component({ CO2 A 2
selector: 'app-root',
templateUrl: './app.component.html',
styleUrls: ['./app.component.css']
})
export class AppComponent {
componentName: string = '';
onKey(componentName: string): void {
this.componentName = componentName;
}
}
When does ngOnChanges life cycle method executes? Write syntax if the value
8 CO3 A 2
of property name is changed from college to rcti.
Write a code to create student service class as injector that contains student array
9 CO4 A 2
and getstudents method.
Write a code that provides an example of an Angular routing module (app-
10 routing.module.ts) that sets up routes for a product list and product details page, CO5 A 2
with a redirect to the product list as the default route?"
VISION: To mould young and fresh minds into challenging computer professionals with ethical values and shaping them with upcoming technologies and develop the ability to
deal with real world situations with skills and innovative ideas.