HTML/JavaScript Web Application Answers

Questions: 680

Answers by our Experts: 648

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Search & Filtering

I want to pass all test cases

Sample Output 1

Item Found

Sample Output 2

Category Not Found

let inputString = "";

let currentLine = 0;

process.stdin.on("data", (inputStdin) => {

 inputString += inputStdin;

});

process.stdin.on("end", (_) => {

 inputString = inputString.trim().split("\n").map((str) => str.trim());

 main();

});

function readLine() {

 return inputString[currentLine++];

}

function main() {

 const categoryOfItem = readLine();

 const item = readLine();

 const mart = [

  {

   category:"pulses",

   items: ["green gram", "green peas", "Turkish gram"]

  },

  {

   category:"soaps",

   items:["santoor", "dove", "lux", "pears"]

  },

 ]; 

 /* Write your code here */

}



In this assignment, let's build a Articles Page by applying the concepts we learned till now. You can use the Bootstrap concepts and CCBP UI Kit as well.


I want pass all test cases

Sample Input 1

8
4

Sample Output 1

2
576
1024

"use strict";

process.stdin.resume();

process.stdin.setEncoding("utf-8");

let inputString = "";

let currentLine = 0;

process.stdin.on("data", (inputStdin) => {

 inputString += inputStdin;

});

process.stdin.on("end", (_) => {

 inputString = inputString.trim().split("\n").map((str) => str.trim());

 main();

});

function readLine() {

 return inputString[currentLine++];

}

function ArithmeticOperations(firstNumber, secondNumber) {

 this.firstNumber = firstNumber;

 this.secondNumber = secondNumber;

}

function main() {

 const firstNumber = JSON.parse(readLine());

 const secondNumber = JSON.parse(readLine());

 const operation1 = new ArithmeticOperations(firstNumber, secondNumber);

 /* Write your code here */

 console.log(operation1.ratioOfNumbers());

 console.log(operation1.sumOfCubesOfNumbers());

 console.log(operation1.productOfSquaresOfNumbers());

}



I want pass all test cases

Sample Input 1

7

Sample Output 1

153.86
43.96

Sample Input 2

25

Sample Output 2

1962.5
157

"use strict";

process.stdin.resume();

process.stdin.setEncoding("utf-8");

let inputString = "";

let currentLine = 0;

process.stdin.on("data", (inputStdin) => {

 inputString += inputStdin;

});

process.stdin.on("end", (_) => {

 inputString = inputString.trim().split("\n").map((str) => str.trim());

 main();

});

function readLine() {

 return inputString[currentLine++];

}

/* Please do not modify anything above this line */

function Circle(radius) { 

 /* Write your code here */

}

/* Please do not modify anything below this line */

function main() {

 const radius = JSON.parse(readLine());

 const circle1 = new Circle(radius);

 console.log(circle1.getArea());

 console.log(circle1.getCircumference());

}



I want to pass all test cases

Sample Input 1

Kukatpally
Hyderabad

Sample Output 1

Kukatpally Hyderabad

"use strict";

process.stdin.resume();

process.stdin.setEncoding("utf-8");

let inputString = "";

let currentLine = 0;

process.stdin.on("data", (inputStdin) => {

 inputString += inputStdin;

});

process.stdin.on("end", (_) => {

 inputString = inputString.trim().split("\n").map((str) => str.trim());

 main();

});

function readLine() {

 return inputString[currentLine++];

}

/* Please do not modify anything above this line */

function createCabBooking(area, city) {

 /* Write your code here */

}

/* Please do not modify anything below this line */

function main() {

 const newArea = readLine();

 const newCity = readLine();

 const cabBooking1 = createCabBooking("Abids", "Hyderabad");

 cabBooking1.updatePickupPoint(newArea, newCity);

 console.log(`${cabBooking1.area} ${cabBooking1.city}`);

}





I want to pass all the test cases

Sample Input 1

1000
2
3

Sample Output 1

1060

Sample Input 2

2000

Sample Output 2

2200


"use strict";


process.stdin.resume();

process.stdin.setEncoding("utf-8");


let inputString = "";

let currentLine = 0;


process.stdin.on("data", (inputStdin) => {

 inputString += inputStdin;

});


process.stdin.on("end", (_) => {

 inputString = inputString.trim().split("\n").map((str) => str.trim());

 main();

});


function readLine() {

 let input = inputString[currentLine++]; 

 return input === undefined ? undefined : JSON.parse(input);

}


/* Please do not modify anything above this line */

  

 /* Write your code here */ 


/* Please do not modify anything below this line */


function main() {

 const principal = readLine();

 const time = readLine();

 const apprPercentage = readLine();


 const finalValue = calculateFinalValueWithAppreciation(principal, time, apprPercentage);


 console.log(finalValue);

}


I want to pass all the test cases

Sample Input 1

200
3

Sample Output 1

570

Sample Input 2

180
1

Sample Output 2

180



"use strict";

process.stdin.resume();

process.stdin.setEncoding("utf-8");

let inputString = "";

let currentLine = 0;

process.stdin.on("data", (inputStdin) => {

 inputString += inputStdin;

});

process.stdin.on("end", (_) => {

 inputString = inputString.trim().split("\n").map((str) => str.trim());

 main();

});

function readLine() {

 return inputString[currentLine++];

}

/* Please do not modify anything above this line */

function main() {

 const dayCharge = JSON.parse(readLine());

 const days = parseInt(readLine()); 

 /* Write your code here */

}


How to create a webpage


out of 2 testcases, only 1 testcase is getting fail where its loged in console as NAN. write a Javascript function to return the final value finalValue with the given appreciation percentage and time period. Input

The first line of input contains a number principal

The second line (optional) of input contains a number time

The third line (optional) of input contains a number apprPercentage

Output

The output should be a single line containing the finalValue

Final Value with Appreciation:The formula to calculate the final value with appreciation is, finalValue = principal * (1 + time * appreciation / 100).

Given principal amount

principal as an input, time period in years time and appreciation percentage apprPercentage as optional inputs, write a Javascript function to return the final value finalValue with the given appreciation percentage and time period. The default values for time and apprPercentage are 2 and 5 respectively.

Input1:

1000

2

3

Expected

1060

input2:

2000

Expected

2200


Write and demonstrate (at the time of viva) JavaScript code that displays the message "Welcome to BCA" and changes this text to “Web Programming is essential for BCA" after 10 seconds. You may use event handling. Make suitable assumptions, if any. 


LATEST TUTORIALS
New on Blog
APPROVED BY CLIENTS