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

run at pycharm community

PYTHON CREATING CLASS AND ATTRIBUTE :







1. Create a Class and initialize attribute of the following:




Class name: Student




Attribute: First Name




Last Name




Sex




Age







2. From the created class, create 5 objects, and display it using pretty table.

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}`);

}





Write a program that calculates and prints

the take-home pay for a commissioned sales

employee. Allow the user to enter values for the

name of the employee and the sales amount


1.Create a datatype Rectangle, where a Rectangle is defined by Length & Width. Your Program should be capable to compute:

uArea (LxW)

uPerimeter 2(L+W)

ucompare two rectangles with respect to the area and return true if two rectangles are equal, False otherwise


Write a python program that reads a sentence


The placement session has begun in a college. There is N number of students standing outside an interview room in a line. It is given that the person who goes first has higher chances of selection.


Each student has a number associated with them representing their problem-solving capability. The higher the capability the higher the chances of selection. Now every student wants to know the number of students ahead of him with higher problem-solving capability.


Input: 6(number of students) {4 , 9 , 5 , 3 , 2 , 10}


Output: {0 , 0 , 1 , 3 , 4 , 0}





The placement session has begun in a college. There is N number of students standing outside an interview room in a line. It is given that the person who goes first has higher chances of selection.


Each student has a number associated with them representing their problem-solving capability. The higher the capability the higher the chances of selection. Now every student wants to know the number of students ahead of him with higher problem-solving capability.


Input: 6(number of students) {4 , 9 , 5 , 3 , 2 , 10}


Output: {0 , 0 , 1 , 3 , 4 , 0}





The placement session has begun in a college. There is N number of students standing outside an interview room in a line. It is given that the person who goes first has higher chances of selection.




Each student has a number associated with them representing their problem-solving capability. The higher the capability the higher the chances of selection. Now every student wants to know the number of students ahead of him with higher problem-solving capability.




Input: 6(number of students) {4 , 9 , 5 , 3 , 2 , 10}




Output: {0 , 0 , 1 , 3 , 4 , 0}







1. Calculate the value of a function y=2x^2+15 with x varying from 1 to 20 in increments of 0.5.



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);

}


LATEST TUTORIALS
APPROVED BY CLIENTS