public class Person { private String name; private int age;.pdfarjuncp10
public class Person
{
private String name;
private int age;
public Person()
{
name=\"\";
age=0;
}
/**
Create a person with a given name and age.
@param name the name
@param age the age
*/
public Person(String name, int age)
{
this.name = name;
this.age = age;
}
/**
Get the name.
@return the name
*/
public String getName()
{
return name;
}
/**
Change the name.
@param name the name
*/
public void setName(String name)
{
this.name = name;
}
/**
Get the age.
@return the age
*/
public int getAge()
{
return age;
}
/**
Change the age.
@param age the age
*/
public void setAge()
{
this.age = age;
}
/**
Convert person to string form.
*/
public String toString()
{
return \"Name: \" + name + \"\\t\" + \"Age: \" + age;
}
}
OUTPUT should look like this!
Solution
solution
package com.prt.test;
public class Person
{
protected String name;
protected int age;
public Person()
{
name=\"\";
age=0;
}
/**
Create a person with a given name and age.
@param name the name
@param age the age
*/
public Person(String name, int age)
{
this.name = name;
this.age = age;
}
/**
Get the name.
@return the name
*/
public String getName()
{
return name;
}
/**
Change the name.
@param name the name
*/
public void setName(String name)
{
this.name = name;
}
/**
Get the age.
@return the age
*/
public int getAge()
{
return age;
}
/**
Change the age.
@param age the age
*/
public void setAge()
{
this.age = age;
}
/**
Convert person to string form.
*/
public String toString()
{
return \"Name: \" + name + \"\\t\" + \"Age: \" + age;
}
}
package com.prt.test;
public class Student extends Person implements Comparable{
private int studentId;
private String major;
/**
* @return the studentId
*/
public int getStudentId() {
return studentId;
}
/**
* @param studentId the studentId to set
*/
public void setStudentId(int studentId) {
this.studentId = studentId;
}
/**
* @return the major
*/
public String getMajor() {
return major;
}
/**
* @param major the major to set
*/
public void setMajor(String major) {
this.major = major;
}
public Student(String name, int age, int studentId, String major) {
super(name, age);
this.studentId = studentId;
this.major = major;
}
/* (non-Javadoc)
* @see java.lang.Object#toString()
*/
@Override
public String toString() {
return \"name:\" + name+ \"\\t\"+\"\\t\"+\"age:\"+ age+\"\\t\"+ \"studentId :\"+ studentId +
\"\\t\" +\" major:\"+ major;
}
public int compareTo(Student st){
if(studentId==st.studentId)
return 0;
else if(studentId>st.studentId)
return 1;
else
return -1;
}
}
package com.prt.test;
public class Instructor extends Person implements Comparable {
private double salary;
public Instructor(String name, int age, double salary) {
super(name, age);
this.salary = salary;
}
/**
* @return the salary
*/
public double getSalary() {
return salary;
}
/**
* @param salary
* the salary to set
*/
public void setSalary(double salary) {
this.salary = salary;
}
public int compareTo(Instructor is) {
if (salary == is.salary)
return 0;
else if (salary > is.salary)
return 1;
else
ret.
29. Code an application program that keeps track of student informat.pdfarishaenterprises12
29. Code an application program that keeps track of student information at your college. Include
their names, identification numbers, and grade point averages in a fully encapsulated,
homogeneous sorted singly linked list structure. When launched, the user will be asked to input
the initial number of students and the initial data set. Once this is complete, the user will be
presented with the following menu: Enter: 1 to insert a new student\'s information, 2 to fetch and
output a student\'s information, 3 to delete a student\'s information, 4 to update a student\'s
information, 5 to output all the student information in sorted order, and 6 to exit the program.
The program should perform an unlimited number of operations until the user enters a 6 to exit
the program. If the user requests an operation on a node not in the structure, the program output
should be “node not in structure.” Otherwise, the message “operation complete” should be
output. in java
Solution
Dear Asker,
Following 3 classes consist the colution to this problem. This will give you an idea to approach
this problem:
//Student Class
package studentinfo;
public class Student implements Comparable {
private String name;
private String id;
private double gpa;
public Student(String id, String name, double gpa) {
this.name = name;
this.id = id;
this.gpa = gpa;
}
/**
* @return the name
*/
public String getName() {
return name;
}
/**
* @param name the name to set
*/
public void setName(String name) {
this.name = name;
}
/**
* @return the id
*/
public String getId() {
return id;
}
/**
* @param id the id to set
*/
public void setId(String id) {
this.id = id;
}
/**
* @return the gpa
*/
public double getGpa() {
return gpa;
}
/**
* @param gpa the gpa to set
*/
public void setGpa(double gpa) {
this.gpa = gpa;
}
@Override
public int compareTo(Student o) {
if (this.id.compareTo(o.id) < 0) {
return -1;
} else if (this.id.compareTo(o.id) > 0) {
return 1;
} else if (this.gpa < o.gpa) {
return -1;
} else if (this.gpa > o.gpa) {
return 1;
}
return 0;
}
public boolean equals(Student o) {
if (this.name == o.name && this.id == o.id && this.gpa == o.gpa) {
return true;
}
return false;
}
}
//Student container class
package studentinfo;
import java.util.Collections;
import java.util.LinkedList;
public class StudentContainer {
LinkedList studentList;
public StudentContainer() {
this.studentList = new LinkedList();
}
public boolean hasStudent(String id, String name, double gpa) {
return this.studentList.contains(new Student(id, name, gpa));
}
public boolean insertStudent(String id, String name, double gpa) {
if (!this.isValidString(id) || !this.isValidString(name) || !this.isValidGpa(gpa)) {
return false;
}
this.studentList.add(new Student(id, name, gpa));
return true;
}
public boolean deleteStudentById(String id) {
Student toRemove = null;
for (Student e : studentList) {
if (e.getId() == id) {
toRemove = e;
break;
}
}
if (toRemove != null) {
this.studentList.remove(toRemove);
return true;
}
return false;.
Can someone help me with this code When I run it, it stops after th.pdfAmansupan
Can someone help me with this code? When I run it, it stops after the output
Enter Student 1 Details
Name
I would just like to know what is incorrect with my code & how I can fix it.
Here is my code:
package studentclient;
import java.util.Scanner;
public class StudentClient {
public static void main(String[] args) {
Student s1;
Student s2;
s1 = new Student(\"Lisa\", \"111-11-111\", 3.0);
s2 = new Student(\"Jacob\", \"777-77-777\", 4.0);
System.out.println(\"Enter Student 1 Details\");
System.out.println(\"Name\");
Scanner sc=new Scanner(System.in);
String Name = sc.next();
System.out.println(\"Social Security number\");
String Ssn = sc.next();
System.out.println(\"GPA\");
double gpa = sc.nextDouble();
System.out.println(\"Enter Student 2 Details\");
System.out.println(\"Name\");
Name=sc.next();
System.out.println(\"social security number\");
Ssn=sc.next();
System.out.println(\"GPA\");
gpa=sc.nextDouble();
System.out.println(\"Student 1 deatils\");
System.out.println(\"name\"+s1.getName());
System.out.println(\"Social Secuirty Number:\"+s1.getSsn());
System.out.println(\"GPA:\"+s1.getGpa());
System.out.println(\"Student 2 details\");
System.out.println(\"name\"+s2.getName());
System.out.println(\"Social Security Number:\"+s2.getSsn());
System.out.println(\"GPA:\"+s2.getGpa());
if(s1 ==(s2))
System.out.println(\"Student details are equal\");
else
System.out.println(\"Student details are not equal\");
s2 = new Student(\"Jacob\", \"000-00-000\", 4.0);
System.out.println(\"Enter new details for Student 2\");
System.out.println(\"Name:\");
Name=sc.next();
s2.setName();
System.out.println(\"Social Security number\");
Ssn=sc.next();
s2.setSsn(Ssn);
System.out.println(\"GPA\");
gpa=sc.nextDouble();
s2.setGpa(gpa);
if(s1 ==(s2))
System.out.println(\"Student details are equal\");
else
System.out.println(\"Student details are not equal\");
}
}
package studentclient;
class Student {
String name;
String social_security_number;
double GPA;
public Student( String newName, String newSsn, double newGpa )
{
this.name=newName;
this.social_security_number=newSsn;
this.GPA=newGpa;
}
public String getName( )
{
return this.name;
}
public void setName( String newName )
{
this.name=newName;
}
public String getSsn( )
{
return this.social_security_number;
}
public void setSsn( String newSsn )
{
// Your code here
this.social_security_number=newSsn;
}
public double getGpa( )
{
return this.GPA;
}
public void setGpa( double newGpa )
{
if(newGpa<0 || newGpa>4)
System.out.println(\"Error! Gpa value should be in the range(0 to 4 ) only.\");
else
this.GPA=newGpa;
}
@Override
public String toString( )
{
return (\"name:\"+this.name+\" Social Security number:\"+this.social_security_number+ \"
GPA:\"+this.GPA);
}
public boolean equals( Student S )
{
boolean ans=false;
if(this.name.equals(S.name) && this.social_security_number.equals(S.social_security_number)
&&this.GPA==S.GPA)
{
ans=true;
}
return ans;
}
void setName() {
throw new UnsupportedOperationException(\"Not supported yet..
public class Person { private String name; private int age;.pdfarjuncp10
public class Person
{
private String name;
private int age;
public Person()
{
name=\"\";
age=0;
}
/**
Create a person with a given name and age.
@param name the name
@param age the age
*/
public Person(String name, int age)
{
this.name = name;
this.age = age;
}
/**
Get the name.
@return the name
*/
public String getName()
{
return name;
}
/**
Change the name.
@param name the name
*/
public void setName(String name)
{
this.name = name;
}
/**
Get the age.
@return the age
*/
public int getAge()
{
return age;
}
/**
Change the age.
@param age the age
*/
public void setAge()
{
this.age = age;
}
/**
Convert person to string form.
*/
public String toString()
{
return \"Name: \" + name + \"\\t\" + \"Age: \" + age;
}
}
OUTPUT should look like this!
Solution
solution
package com.prt.test;
public class Person
{
protected String name;
protected int age;
public Person()
{
name=\"\";
age=0;
}
/**
Create a person with a given name and age.
@param name the name
@param age the age
*/
public Person(String name, int age)
{
this.name = name;
this.age = age;
}
/**
Get the name.
@return the name
*/
public String getName()
{
return name;
}
/**
Change the name.
@param name the name
*/
public void setName(String name)
{
this.name = name;
}
/**
Get the age.
@return the age
*/
public int getAge()
{
return age;
}
/**
Change the age.
@param age the age
*/
public void setAge()
{
this.age = age;
}
/**
Convert person to string form.
*/
public String toString()
{
return \"Name: \" + name + \"\\t\" + \"Age: \" + age;
}
}
package com.prt.test;
public class Student extends Person implements Comparable{
private int studentId;
private String major;
/**
* @return the studentId
*/
public int getStudentId() {
return studentId;
}
/**
* @param studentId the studentId to set
*/
public void setStudentId(int studentId) {
this.studentId = studentId;
}
/**
* @return the major
*/
public String getMajor() {
return major;
}
/**
* @param major the major to set
*/
public void setMajor(String major) {
this.major = major;
}
public Student(String name, int age, int studentId, String major) {
super(name, age);
this.studentId = studentId;
this.major = major;
}
/* (non-Javadoc)
* @see java.lang.Object#toString()
*/
@Override
public String toString() {
return \"name:\" + name+ \"\\t\"+\"\\t\"+\"age:\"+ age+\"\\t\"+ \"studentId :\"+ studentId +
\"\\t\" +\" major:\"+ major;
}
public int compareTo(Student st){
if(studentId==st.studentId)
return 0;
else if(studentId>st.studentId)
return 1;
else
return -1;
}
}
package com.prt.test;
public class Instructor extends Person implements Comparable {
private double salary;
public Instructor(String name, int age, double salary) {
super(name, age);
this.salary = salary;
}
/**
* @return the salary
*/
public double getSalary() {
return salary;
}
/**
* @param salary
* the salary to set
*/
public void setSalary(double salary) {
this.salary = salary;
}
public int compareTo(Instructor is) {
if (salary == is.salary)
return 0;
else if (salary > is.salary)
return 1;
else
ret.
29. Code an application program that keeps track of student informat.pdfarishaenterprises12
29. Code an application program that keeps track of student information at your college. Include
their names, identification numbers, and grade point averages in a fully encapsulated,
homogeneous sorted singly linked list structure. When launched, the user will be asked to input
the initial number of students and the initial data set. Once this is complete, the user will be
presented with the following menu: Enter: 1 to insert a new student\'s information, 2 to fetch and
output a student\'s information, 3 to delete a student\'s information, 4 to update a student\'s
information, 5 to output all the student information in sorted order, and 6 to exit the program.
The program should perform an unlimited number of operations until the user enters a 6 to exit
the program. If the user requests an operation on a node not in the structure, the program output
should be “node not in structure.” Otherwise, the message “operation complete” should be
output. in java
Solution
Dear Asker,
Following 3 classes consist the colution to this problem. This will give you an idea to approach
this problem:
//Student Class
package studentinfo;
public class Student implements Comparable {
private String name;
private String id;
private double gpa;
public Student(String id, String name, double gpa) {
this.name = name;
this.id = id;
this.gpa = gpa;
}
/**
* @return the name
*/
public String getName() {
return name;
}
/**
* @param name the name to set
*/
public void setName(String name) {
this.name = name;
}
/**
* @return the id
*/
public String getId() {
return id;
}
/**
* @param id the id to set
*/
public void setId(String id) {
this.id = id;
}
/**
* @return the gpa
*/
public double getGpa() {
return gpa;
}
/**
* @param gpa the gpa to set
*/
public void setGpa(double gpa) {
this.gpa = gpa;
}
@Override
public int compareTo(Student o) {
if (this.id.compareTo(o.id) < 0) {
return -1;
} else if (this.id.compareTo(o.id) > 0) {
return 1;
} else if (this.gpa < o.gpa) {
return -1;
} else if (this.gpa > o.gpa) {
return 1;
}
return 0;
}
public boolean equals(Student o) {
if (this.name == o.name && this.id == o.id && this.gpa == o.gpa) {
return true;
}
return false;
}
}
//Student container class
package studentinfo;
import java.util.Collections;
import java.util.LinkedList;
public class StudentContainer {
LinkedList studentList;
public StudentContainer() {
this.studentList = new LinkedList();
}
public boolean hasStudent(String id, String name, double gpa) {
return this.studentList.contains(new Student(id, name, gpa));
}
public boolean insertStudent(String id, String name, double gpa) {
if (!this.isValidString(id) || !this.isValidString(name) || !this.isValidGpa(gpa)) {
return false;
}
this.studentList.add(new Student(id, name, gpa));
return true;
}
public boolean deleteStudentById(String id) {
Student toRemove = null;
for (Student e : studentList) {
if (e.getId() == id) {
toRemove = e;
break;
}
}
if (toRemove != null) {
this.studentList.remove(toRemove);
return true;
}
return false;.
Can someone help me with this code When I run it, it stops after th.pdfAmansupan
Can someone help me with this code? When I run it, it stops after the output
Enter Student 1 Details
Name
I would just like to know what is incorrect with my code & how I can fix it.
Here is my code:
package studentclient;
import java.util.Scanner;
public class StudentClient {
public static void main(String[] args) {
Student s1;
Student s2;
s1 = new Student(\"Lisa\", \"111-11-111\", 3.0);
s2 = new Student(\"Jacob\", \"777-77-777\", 4.0);
System.out.println(\"Enter Student 1 Details\");
System.out.println(\"Name\");
Scanner sc=new Scanner(System.in);
String Name = sc.next();
System.out.println(\"Social Security number\");
String Ssn = sc.next();
System.out.println(\"GPA\");
double gpa = sc.nextDouble();
System.out.println(\"Enter Student 2 Details\");
System.out.println(\"Name\");
Name=sc.next();
System.out.println(\"social security number\");
Ssn=sc.next();
System.out.println(\"GPA\");
gpa=sc.nextDouble();
System.out.println(\"Student 1 deatils\");
System.out.println(\"name\"+s1.getName());
System.out.println(\"Social Secuirty Number:\"+s1.getSsn());
System.out.println(\"GPA:\"+s1.getGpa());
System.out.println(\"Student 2 details\");
System.out.println(\"name\"+s2.getName());
System.out.println(\"Social Security Number:\"+s2.getSsn());
System.out.println(\"GPA:\"+s2.getGpa());
if(s1 ==(s2))
System.out.println(\"Student details are equal\");
else
System.out.println(\"Student details are not equal\");
s2 = new Student(\"Jacob\", \"000-00-000\", 4.0);
System.out.println(\"Enter new details for Student 2\");
System.out.println(\"Name:\");
Name=sc.next();
s2.setName();
System.out.println(\"Social Security number\");
Ssn=sc.next();
s2.setSsn(Ssn);
System.out.println(\"GPA\");
gpa=sc.nextDouble();
s2.setGpa(gpa);
if(s1 ==(s2))
System.out.println(\"Student details are equal\");
else
System.out.println(\"Student details are not equal\");
}
}
package studentclient;
class Student {
String name;
String social_security_number;
double GPA;
public Student( String newName, String newSsn, double newGpa )
{
this.name=newName;
this.social_security_number=newSsn;
this.GPA=newGpa;
}
public String getName( )
{
return this.name;
}
public void setName( String newName )
{
this.name=newName;
}
public String getSsn( )
{
return this.social_security_number;
}
public void setSsn( String newSsn )
{
// Your code here
this.social_security_number=newSsn;
}
public double getGpa( )
{
return this.GPA;
}
public void setGpa( double newGpa )
{
if(newGpa<0 || newGpa>4)
System.out.println(\"Error! Gpa value should be in the range(0 to 4 ) only.\");
else
this.GPA=newGpa;
}
@Override
public String toString( )
{
return (\"name:\"+this.name+\" Social Security number:\"+this.social_security_number+ \"
GPA:\"+this.GPA);
}
public boolean equals( Student S )
{
boolean ans=false;
if(this.name.equals(S.name) && this.social_security_number.equals(S.social_security_number)
&&this.GPA==S.GPA)
{
ans=true;
}
return ans;
}
void setName() {
throw new UnsupportedOperationException(\"Not supported yet..
Java questionI am having issues returning the score sort in numeri.pdfforwardcom41
Java question
I am having issues returning the score sort in numerical order for more than 2 entries. I had to
develop an enhancement which allowed the application to sort the list by score. The easiest
solution is probably to create a second student class (perhaps called StudentScore) that
implements the IComparable interface to sort by score rather than by name
StudentSortApp
import java.util.*;
public class StudentSortApp
{
public static void main(String[] args)
{
System.out.println(\"Welcome to the Student Scores Application.\"+\"\ \");
Scanner sc = new Scanner(System.in);
System.out.print(\"Enter number of students to enter: \");
int numberofStudents = sc.nextInt();
//arrays storing student name and score
Student[] students = new Student[numberofStudents];
StudentScore [] studentScores = new StudentScore [numberofStudents];
int t = 0;
for (int i = 0; i < numberofStudents; i++)
{
System.out.println(\"\");
String studentLastName = Validator.lastName(sc, \"Student \" + (i+1) + \" Last name: \");
String studentFirstName = Validator.lastName(sc, \"Student \" + (i+1) + \" First name: \");
int studentScore = Validator.validScore(sc, \"Student \" + (i+1) + \" score : \");
students [t] = new Student(studentFirstName, studentLastName , studentScore);
studentScores [t] = new StudentScore(studentFirstName, studentLastName , studentScore);
t = t + 1;
}
//output
System.out.println(\"\");
System.out.println(\"Last Name Sort\");
Arrays.sort(students, 0, numberofStudents);
for(Student i: students)
System.out.println(i.getlastName()+\", \"+i.getfirstName()+\": \"+i.getScore());
System.out.println();
System.out.println(\"Score Sort\");
Arrays.sort(studentScores, 0, numberofStudents);
for(StudentScore i: studentScores)
System.out.println(i.getlastName()+\", \"+i.getfirstName()+\": \"+i.getScore());
}
}
Validator Class
import java.util.Scanner;
public class Validator
{
public static int validScore(Scanner sc, String prompt)
{
int studentScore = 0;
boolean isValid = false;
while (isValid == false)
{
System.out.print (prompt);
studentScore = sc.nextInt();
if (studentScore > 100 || studentScore < 0)
{
System.out.println(\"Error! You have to enter a score between 0 and 100\");
}
else
{
isValid = true;
}
}
return studentScore;
}
public static String lastName(Scanner sc, String prompt)
{
Scanner input = new Scanner(System.in);
String StudentName = \"\";
boolean isvalid = false;
while (isvalid == false)
{
System.out.print (prompt);
StudentName = input.nextLine();
if (StudentName == null || StudentName.equals(\"\"))
{
System.out.println(\"Error! You have to enter a name.\");
}
else
{
isvalid = true;
}
}
return StudentName;
}
}
Student Class
public class Student implements Comparable
{
private String firstName = \"\";
private String lastName = \"\";
private int score = 0;
// Student Class constructor
public Student(String firstName, String lastName, int score)
{
this.firstName = firstName;
this.lastName = lastName;
this.score = score;
}
@Override
public int compareTo.
Hello. Im currently working on the last section to my assignment a.pdfirshadkumar3
Hello. I\'m currently working on the last section to my assignment and I\'m running into issues.
I\'ll post a screenshot of the directions provided to us, my 5 classes, and a screenshot of my
console output. Can you help me fix my code? I don\'t know where it\'s going wrong and I can\'t
figure it out. Please leave comments on what I did wrong so I can learn from it. Thank you so
much!
Here is the instructions from the pdf for reference on what I\'m trying to accomplish.
package campus;
public class Person {
private String id;
private String lastName;
private String firstName;
public Person(String id, String last, String first)
{
this.id = id;
this.lastName = last;
this.firstName = first;
}
public String getLastName() {
return lastName;
}
public void setLastName(String lastName) {
this.lastName = lastName;
}
public String getFirstName() {
return firstName;
}
public void setFirstName(String firstName) {
this.firstName = firstName;
}
public String getId() {
return id;
}
public String toString()
{
return id + \": \" + firstName + \" \" + lastName;
}
}
------
---Student.java---
package campus;
public class Student extends Person {
private String major;
private int level;
private Person obj;
public Student(String id, String last, String first, String focus, int level) {
super(id, last, first);// calling parent constructor
this.major = focus;
this.level = level;
obj = new Person(id, last, first);
}
public String getMajor() {
return major;
}
public void setMajor(String major) {
this.major = major;
}
public int getLevel() {
return level;
}
public void setLevel(int level) {
this.level = level;
}
@Override
public String toString() { // override toString() method
return \"id: \" + obj.getId() + \", Name: \" + obj.getFirstName() + \" \" + obj.getLastName()
+ \", major is \"
+ this.major + \" and their level is \" + this.level;
}
}
------
---Faculty.java---
package campus;
public class Faculty extends Person {
private String dept;
private String rank;
private Person obj;
public Faculty(String id, String last, String first, String focus, int level) {
super(id, last, first);// calling parent constructor
}
public String getDept() {
return dept;
}
public void setDept(String dept) {
this.dept = dept;
}
public String getRank() {
return rank;
}
public void setRank(int level) {
this.rank = rank;
}
@Override
public String toString() { // override toString() method
return \"id: \" + obj.getId() + \", Name: \" + obj.getFirstName() + \" \" + obj.getLastName()
+ \", deptartment is \"
+ this.dept + \" and their rank is \" + this.rank;
}
}
------
---Section.java---
package campus;
public class Section {
private String id;
private Faculty instructor;
private Student[] enrolled;
private int numofEnroll;
private int capacity;
private String location;
private String time;
private String semester;
public Section(String id, Faculty instructor, int capacity, String location, String time, String
semester) {
}
public Section(String id, int capacity) {
this.id = id;
this.capacity .
Create a class named Student that has the following member variables.pdfarrowvisionoptics
Create a class named Student that has the following member variables: first name (string), last
name(string), student identification number(int), an integer array where the grades of all classes
are stored, grade point average (gpa) (float). Write appropriate constructor, mutator and accessor
functions for the class along with the following A function that inputs all values from the user
(except for gpa) A function that outputs the names and gpa of students
Solution
/* Java Programme for Grades Calculation */
import java.util.Scanner;
public class Student
{
//Private varibles declaration
private String firstName;
private String lastName;
private int sid;
private int[] grades= new int[10];
int[] tempgrades= new int[10];
int noc;
private float gpa=0;
//Constructor method
Scanner in=new Scanner(System.in); //scanner class object for reading input
public static void main(String[] args)
{
Student st=new Student(); //creating object and calling default constructor
st.readInput();
st.calgpa();
}
//Mutator for firstName
public void setfirstName(String firstName)
{
this.firstName = firstName;
}
//Mutator for lastName
public void setlastName(String lastName)
{
this.lastName = lastName;
}
//Mutator for sid
public void setsid(int sid)
{
this.sid = sid;
}
//Mutator for grades
public void setgrades(int[] grades)
{
this.grades = grades;
}
void readInput() //Function to read input data
{
System.out.println(\"Enter First Name\ \"); //Prompt for name
String temp=in.nextLine(); //reading name
setfirstName(temp); //calling mutator for firstName
System.out.println(\"Enter Last Name\ \"); //Prompt for last name
String temp1=in.nextLine(); //read last anme
setlastName(temp1); //calling mutator for lastName
System.out.println(\"Enter Student ID\ \"); //prompt for student id
int temp2=in.nextInt(); //read student id
setsid(temp2); //calling mutator for sid
System.out.println(\"Enter Number of classes ID\ \"); //Prompt for Number of classes
noc=in.nextInt(); //read Number of classes
System.out.println(\"Enter Grades of classes ID\ \"); //Prompt for Grades of classes
for(int i=0;i Gpa : \" + gpa+\"\ \"); //Dispaly output
}
}
Output :
javac Student.java //Compilation of java programme
java Student //running java programme
Sample output :
Enter First Name
Ashok
Enter Last Name
Kumar
Enter Student ID
101
Enter Number of classes ID
4
Enter Grades of classes ID
10
9
8
7
First Name : Ashok Last Name : Kumar Student Id : 101 --> Gpa : 8.5.
HELP IN JAVACreate a main method and use these input files to tes.pdffatoryoutlets
For the questions below, use the W3Schools customer orders database. You need to submit
thoroughly tested SQL statements. For your convenience and reference, relevant data model is
attached as a PDF document with the assignment in the Blackboard. Name of this document is
\"Relationship diagram for W3schools order pdf.\" 1) Write a query to show Customers\' Country
wise sales totals. Your query should show Customers\' Country name and the total sale value for
that Country 2) Write a query to show Product wise sales totals. Your query should Product
name and the total sale value for that Product. 3) Write a query to show the number of orders for
each shipper. Your query should show shipper name and the count of orders with the shipper. 4)
Write a query to show number of products in each product category. Your query should show
Category name and number of products in that category 5) Write a query that shows Customers\'
country wise customer count, and order count. Your query should show country name, total
number of customers from that country, and total number of orders from the customers of that
country 6) Write a query that shows the number of products supplied by each Supplier. Your
query should show Country name, supplier name and the count of products supplied by that
supplier. Note: Sale Price Orderdetails.Quantity Products.price (see an example in the class
slides deck) W3SCHOOLS SQL is located at http://www.w3schools.com/sql/default.asp
(Preferred browser is Chrome). On this page you will find a button called \"Try it yourself\".
Click on that button. You will be redirected to a page where you see a list of tables on the right
side of the page. It is highly recommended to click \'Restore Database\' button on this page
during every session. The page contains a box where you can type in an SQL statement
involving the listed tables. You type in your SQL statement in that box and click on \"Run
SQL\'\' button. The results will be displayed if your SQL statement is syntactically correct.
Solution
1. SELECT Customers.Country, SUM(OrderDetails.Quantity * Products.Price) AS Total_Sale
FROM Customers
LEFT JOIN Orders ON Customers.CustomerID=Orders.CustomerID
LEFT JOIN OrderDetails ON Orders.OrderId=OrderDetails.OrderId
LEFT JOIN Products ON OrderDetails.ProductId=Products.ProductId
Group BY Customers.Country;
2. SELECT Products.ProductName, SUM(OrderDetails.Quantity * Products.Price) AS
Total_Sale FROM Customers
LEFT JOIN Orders ON Customers.CustomerID=Orders.CustomerID
LEFT JOIN OrderDetails ON Orders.OrderId=OrderDetails.OrderId
LEFT JOIN Products ON OrderDetails.ProductId=Products.ProductId
Group BY Products.ProductName;
You can edit these query to get other results set..
So Far I have these two classes but I need help with my persontest c.pdfarihantgiftgallery
So Far I have these two classes but I need help with my persontest class:
The next step is to add method calls for the accessor methods after each input:
//Reading and updating values
System.out.print(\"\ Enter Person Name: \");
person1.setPersonName(sc.nextLine());
System.out.println(\"You entered: \" + person1.getPersonName());
Call the accessor function each time you ask for input, after capturing that input. Then repeat for
a second Person, only this time call the constructor that takes the student id as a parameter.
7 import java.util.Scanner;
8
9 class PersonTest
10 {
11 //Main method
12 public static void main(String args[])
13 {
14 Scanner sc = new Scanner(System.in);
15
16 //Creating object
17 Persons_Information person1 = new Persons_Information();
18
19 //Reading and updating values
20 System.out.print(\"\ Enter Person Name: \");
21 person1.setPersonName(sc.nextLine());
22
23 System.out.print(\"\ Enter Current Address: \");
24 person1.setCurrentAdress(sc.nextLine());
25
26 System.out.print(\"\ Enter Permanent Address: \");
27 person1.setpermanentAdress(sc.nextLine());
28
29 System.out.print(\"\ Enter ID number: \");
30 person1.setIdNumber(sc.nextInt());
31
32 sc.nextLine();
33
34 System.out.print(\"\ Enter Birth Date: \");
35 person1.setBirthDate(sc.nextLine());
36
37
38 System.out.print(\"\ Enter Person Age: \");
39 person1.setPersonAge(sc.nextInt());
40
41
42 System.out.print(\"\ Enter Entry Year: \");
43 person1.setEntryYear(sc.nextInt());
44
45
46 System.out.print(\"\ Enter Total Years: \");
47 person1.setTotalYears(sc.nextInt());
48
49 //Printing person 1 details
50 System.out.println(\"\ Person 1: \ \" + person1.toString());
51 }
52 }
Solution
Persons_Information.java
public class Persons_Information {
//Declaring instance variables
private String personName;
private String currentAdress;
private String permanentAdress;
private int idNumber;
private String birthDate;
private int personAge;
private int entryYear;
private int totalYears;
//Zero argumented constructor
public Persons_Information()
{
}
//Parameterized constructor
public Persons_Information(int idNumber) {
this.idNumber = idNumber;
}
//Getters and setters
public String getPersonName() {
return personName;
}
public void setPersonName(String personName) {
this.personName = personName;
}
public String getCurrentAdress() {
return currentAdress;
}
public void setCurrentAdress(String currentAdress) {
this.currentAdress = currentAdress;
}
public String getPermanentAdress() {
return permanentAdress;
}
public void setPermanentAdress(String permanentAdress) {
this.permanentAdress = permanentAdress;
}
public int getIdNumber() {
return idNumber;
}
public void setIdNumber(int idNumber) {
this.idNumber = idNumber;
}
public String getBirthDate() {
return birthDate;
}
public void setBirthDate(String birthDate) {
this.birthDate = birthDate;
}
public int getPersonAge() {
return personAge;
}
public void setPersonAge(int personAge) {
this.personAge = personAge;
}
public int getEntryYe.
operating system linux,ubuntu,Mac Geometri.pdfaquadreammail
//operating system linux,ubuntu,Mac
/*********************GeometricObject.java**********************/
public abstract class GeometricObject {
private String color = \"white\";
private boolean filled;
// default constructure
public GeometricObject() {
super();
// TODO Auto-generated constructor stub
}
// construct a Geometric Object
// parameterized constructure
public GeometricObject(String color, boolean filled) {
this.color = color;
this.filled = filled;
}
/** Getter method for color */
public String getColor() {
return color;
}
/** Setter method for color */
public void setColor(String color) {
this.color = color;
}
/**
* Getter method for filled. Since filled is boolean, so the gret method
* name is isFilled
*/
public boolean isFilled() {
return filled;
}
/** Setter method for filled */
public void setFilled(boolean filled) {
this.filled = filled;
}
/** Abstract method for FindArea */
public abstract double findArea();
/** Abstract method for findPerimeter */
public abstract double findPerimeter();
}
/*****************************Octagon.java**************/
public class Octagon extends GeometricObject implements Cloneable, Comparable {
private double side;
/** construct a Octagon with specified side */
public Octagon(double side) {
super();
this.side = side;
}
/** Implement the abstract method findArea in GeometricObject */
@Override
public double findArea() {
double area = (2 + 4 / Math.sqrt(2)) * side * side;
return area;
}
/** Implement the abstract method findArea in findPerimeter */
@Override
public double findPerimeter() {
double perimeter = 8 * side;
return perimeter;
}
/** Implement the compareTo method in Comparable interface */
@Override
public int compareTo(Object o) {
// TODO Auto-generated method stub
return 0;
}
public Object clone() throws CloneNotSupportedException {
return super.clone();
}
}
/*******************App.java*******************/
public class App {
public static void main(String[] args) {
Octagon a1 = new Octagon(5);//creating object of octagon
System.out.println(\"Area of a1 is \" + a1.findArea());
System.out.println(\"Perimeter of a1 is \" + a1.findPerimeter());
Object a2;
try {
a2 = a1.clone();
String result = (a1.compareTo(a2) == 0) ? \"a1 and its clone a2 have the same area\"
: \"a1 and its clone a2 have different areas\";
System.out.println(\"Compare a1 and its clone a2:\ \\t \" + result);
System.out.println(\"Hashcode of a1: \" + a1.hashCode());
System.out.println(\"Hashcode of a2: \" + a2.hashCode());
System.out.println(\"Displaying a1: \" + a1);
System.out.println(\"Displaying a2: \" + a2);
} catch (CloneNotSupportedException e) {
e.printStackTrace();
}
}
}
/*****************output***************/
gopal@gopal:~/Desktop/chegg$ javac GeometricObject.java
gopal@gopal:~/Desktop/chegg$ javac Octagon.java
gopal@gopal:~/Desktop/chegg$ javac App.java
gopal@gopal:~/Desktop/chegg$ java App
Area of a1 is 120.71067811865476
Perimeter of a1 is 40.0
Compare a1 and its clone a2:
a1 and its clone a2 have the same area
.
Listing.javaimport java.util.Scanner;public class Listing { .pdfAnkitchhabra28
Listing.java
import java.util.Scanner;
public class Listing {
//Declaring instance variables
private String name;
private int age;
//Default constructor
public Listing() {
name=\" \";
age=0;
}
//parameterized Constructor
public Listing(String name, int age) {
super();
this.name = name;
this.age = age;
}
//Getters and setters
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
public int getAge() {
return age;
}
public void setAge(int age) {
this.age = age;
}
//This input() method will take the inputs entered by the user.
public void input()
{
//Scanner Object is used to get the data entered by the user
Scanner sc=new Scanner(System.in);
//Getting the user name
System.out.print(\"Enter Name :\");
setName(sc.nextLine());
//Getting the Age
System.out.print(\"Enter Age :\");
setAge(sc.nextInt());
}
//This toString() method will displays the constents of the user.
@Override
public String toString() {
System.out.println(\"Name :\"+getName());
System.out.println(\"Name :\"+getAge());
return \"\";
}
}
_____________________________________________________________
Driver.java
public class Driver {
public static void main(String[] args) {
//Create an array of 3 Listing Objects
Listing listing[]=new Listing[3];
//Creating Listing Objects and populating into an Array
for(int i=0;i<3;i++)
{
listing[i]=new Listing();
System.out.println(\"Listing Object \"+(i+1)+\":\");
//Calling the input method which capture the data entered by the user
listing[i].input();
}
//Displaying the Listing objects in the Normal Order
System.out.println(\"Displaying the Listing Objects in the Normal Order ::\");
for(int i=0;i<3;i++)
{
System.out.println(\"Listing Object \"+(i+1)+\":\");
listing[i].toString();
System.out.println(\"_____________________\");
}
//Displaying the Listing objects in the Reverse Order
System.out.println(\"Displaying the Listing Objects in the Reverse Order ::\");
for(int i=2;i>=0;i--)
{
System.out.println(\"Listing Object \"+(i+1)+\":\");
listing[i].toString();
System.out.println(\"_____________________\");
}
}
}
_______________________________________________________
Output:
Listing Object 1:
Enter Name :Kane Williams
Enter Age :27
Listing Object 2:
Enter Name :John Mills
Enter Age :23
Listing Object 3:
Enter Name :Tim Rochey
Enter Age :22
Displaying the Listing Objects in the Normal Order ::
Listing Object 1:
Name :Kane Williams
Name :27
_____________________
Listing Object 2:
Name :John Mills
Name :23
_____________________
Listing Object 3:
Name :Tim Rochey
Name :22
_____________________
Displaying the Listing Objects in the Reverse Order ::
Listing Object 3:
Name :Tim Rochey
Name :22
_____________________
Listing Object 2:
Name :John Mills
Name :23
_____________________
Listing Object 1:
Name :Kane Williams
Name :27
_____________________
_____________________________________________Thank You
Solution
Listing.java
import java.util.Scanner;
public class Listing {
//Declaring instance variables
private String n.
You have to leave solids and liquids out of the equation. This lea.pdfaplolomedicalstoremr
You have to leave solids and liquids out of the equation.
This leaves only product B for the product, nothing for the reactants.
Initially there was no product B.
At equilibrium: you determine the molarity by multiplying 2.5% by (0.5M/10L)= .00125 =
which rounds to answer E) 1.3e-3
it was a trick question.
Solution
You have to leave solids and liquids out of the equation.
This leaves only product B for the product, nothing for the reactants.
Initially there was no product B.
At equilibrium: you determine the molarity by multiplying 2.5% by (0.5M/10L)= .00125 =
which rounds to answer E) 1.3e-3
it was a trick question..
Java questionI am having issues returning the score sort in numeri.pdfforwardcom41
Java question
I am having issues returning the score sort in numerical order for more than 2 entries. I had to
develop an enhancement which allowed the application to sort the list by score. The easiest
solution is probably to create a second student class (perhaps called StudentScore) that
implements the IComparable interface to sort by score rather than by name
StudentSortApp
import java.util.*;
public class StudentSortApp
{
public static void main(String[] args)
{
System.out.println(\"Welcome to the Student Scores Application.\"+\"\ \");
Scanner sc = new Scanner(System.in);
System.out.print(\"Enter number of students to enter: \");
int numberofStudents = sc.nextInt();
//arrays storing student name and score
Student[] students = new Student[numberofStudents];
StudentScore [] studentScores = new StudentScore [numberofStudents];
int t = 0;
for (int i = 0; i < numberofStudents; i++)
{
System.out.println(\"\");
String studentLastName = Validator.lastName(sc, \"Student \" + (i+1) + \" Last name: \");
String studentFirstName = Validator.lastName(sc, \"Student \" + (i+1) + \" First name: \");
int studentScore = Validator.validScore(sc, \"Student \" + (i+1) + \" score : \");
students [t] = new Student(studentFirstName, studentLastName , studentScore);
studentScores [t] = new StudentScore(studentFirstName, studentLastName , studentScore);
t = t + 1;
}
//output
System.out.println(\"\");
System.out.println(\"Last Name Sort\");
Arrays.sort(students, 0, numberofStudents);
for(Student i: students)
System.out.println(i.getlastName()+\", \"+i.getfirstName()+\": \"+i.getScore());
System.out.println();
System.out.println(\"Score Sort\");
Arrays.sort(studentScores, 0, numberofStudents);
for(StudentScore i: studentScores)
System.out.println(i.getlastName()+\", \"+i.getfirstName()+\": \"+i.getScore());
}
}
Validator Class
import java.util.Scanner;
public class Validator
{
public static int validScore(Scanner sc, String prompt)
{
int studentScore = 0;
boolean isValid = false;
while (isValid == false)
{
System.out.print (prompt);
studentScore = sc.nextInt();
if (studentScore > 100 || studentScore < 0)
{
System.out.println(\"Error! You have to enter a score between 0 and 100\");
}
else
{
isValid = true;
}
}
return studentScore;
}
public static String lastName(Scanner sc, String prompt)
{
Scanner input = new Scanner(System.in);
String StudentName = \"\";
boolean isvalid = false;
while (isvalid == false)
{
System.out.print (prompt);
StudentName = input.nextLine();
if (StudentName == null || StudentName.equals(\"\"))
{
System.out.println(\"Error! You have to enter a name.\");
}
else
{
isvalid = true;
}
}
return StudentName;
}
}
Student Class
public class Student implements Comparable
{
private String firstName = \"\";
private String lastName = \"\";
private int score = 0;
// Student Class constructor
public Student(String firstName, String lastName, int score)
{
this.firstName = firstName;
this.lastName = lastName;
this.score = score;
}
@Override
public int compareTo.
Hello. Im currently working on the last section to my assignment a.pdfirshadkumar3
Hello. I\'m currently working on the last section to my assignment and I\'m running into issues.
I\'ll post a screenshot of the directions provided to us, my 5 classes, and a screenshot of my
console output. Can you help me fix my code? I don\'t know where it\'s going wrong and I can\'t
figure it out. Please leave comments on what I did wrong so I can learn from it. Thank you so
much!
Here is the instructions from the pdf for reference on what I\'m trying to accomplish.
package campus;
public class Person {
private String id;
private String lastName;
private String firstName;
public Person(String id, String last, String first)
{
this.id = id;
this.lastName = last;
this.firstName = first;
}
public String getLastName() {
return lastName;
}
public void setLastName(String lastName) {
this.lastName = lastName;
}
public String getFirstName() {
return firstName;
}
public void setFirstName(String firstName) {
this.firstName = firstName;
}
public String getId() {
return id;
}
public String toString()
{
return id + \": \" + firstName + \" \" + lastName;
}
}
------
---Student.java---
package campus;
public class Student extends Person {
private String major;
private int level;
private Person obj;
public Student(String id, String last, String first, String focus, int level) {
super(id, last, first);// calling parent constructor
this.major = focus;
this.level = level;
obj = new Person(id, last, first);
}
public String getMajor() {
return major;
}
public void setMajor(String major) {
this.major = major;
}
public int getLevel() {
return level;
}
public void setLevel(int level) {
this.level = level;
}
@Override
public String toString() { // override toString() method
return \"id: \" + obj.getId() + \", Name: \" + obj.getFirstName() + \" \" + obj.getLastName()
+ \", major is \"
+ this.major + \" and their level is \" + this.level;
}
}
------
---Faculty.java---
package campus;
public class Faculty extends Person {
private String dept;
private String rank;
private Person obj;
public Faculty(String id, String last, String first, String focus, int level) {
super(id, last, first);// calling parent constructor
}
public String getDept() {
return dept;
}
public void setDept(String dept) {
this.dept = dept;
}
public String getRank() {
return rank;
}
public void setRank(int level) {
this.rank = rank;
}
@Override
public String toString() { // override toString() method
return \"id: \" + obj.getId() + \", Name: \" + obj.getFirstName() + \" \" + obj.getLastName()
+ \", deptartment is \"
+ this.dept + \" and their rank is \" + this.rank;
}
}
------
---Section.java---
package campus;
public class Section {
private String id;
private Faculty instructor;
private Student[] enrolled;
private int numofEnroll;
private int capacity;
private String location;
private String time;
private String semester;
public Section(String id, Faculty instructor, int capacity, String location, String time, String
semester) {
}
public Section(String id, int capacity) {
this.id = id;
this.capacity .
Create a class named Student that has the following member variables.pdfarrowvisionoptics
Create a class named Student that has the following member variables: first name (string), last
name(string), student identification number(int), an integer array where the grades of all classes
are stored, grade point average (gpa) (float). Write appropriate constructor, mutator and accessor
functions for the class along with the following A function that inputs all values from the user
(except for gpa) A function that outputs the names and gpa of students
Solution
/* Java Programme for Grades Calculation */
import java.util.Scanner;
public class Student
{
//Private varibles declaration
private String firstName;
private String lastName;
private int sid;
private int[] grades= new int[10];
int[] tempgrades= new int[10];
int noc;
private float gpa=0;
//Constructor method
Scanner in=new Scanner(System.in); //scanner class object for reading input
public static void main(String[] args)
{
Student st=new Student(); //creating object and calling default constructor
st.readInput();
st.calgpa();
}
//Mutator for firstName
public void setfirstName(String firstName)
{
this.firstName = firstName;
}
//Mutator for lastName
public void setlastName(String lastName)
{
this.lastName = lastName;
}
//Mutator for sid
public void setsid(int sid)
{
this.sid = sid;
}
//Mutator for grades
public void setgrades(int[] grades)
{
this.grades = grades;
}
void readInput() //Function to read input data
{
System.out.println(\"Enter First Name\ \"); //Prompt for name
String temp=in.nextLine(); //reading name
setfirstName(temp); //calling mutator for firstName
System.out.println(\"Enter Last Name\ \"); //Prompt for last name
String temp1=in.nextLine(); //read last anme
setlastName(temp1); //calling mutator for lastName
System.out.println(\"Enter Student ID\ \"); //prompt for student id
int temp2=in.nextInt(); //read student id
setsid(temp2); //calling mutator for sid
System.out.println(\"Enter Number of classes ID\ \"); //Prompt for Number of classes
noc=in.nextInt(); //read Number of classes
System.out.println(\"Enter Grades of classes ID\ \"); //Prompt for Grades of classes
for(int i=0;i Gpa : \" + gpa+\"\ \"); //Dispaly output
}
}
Output :
javac Student.java //Compilation of java programme
java Student //running java programme
Sample output :
Enter First Name
Ashok
Enter Last Name
Kumar
Enter Student ID
101
Enter Number of classes ID
4
Enter Grades of classes ID
10
9
8
7
First Name : Ashok Last Name : Kumar Student Id : 101 --> Gpa : 8.5.
HELP IN JAVACreate a main method and use these input files to tes.pdffatoryoutlets
For the questions below, use the W3Schools customer orders database. You need to submit
thoroughly tested SQL statements. For your convenience and reference, relevant data model is
attached as a PDF document with the assignment in the Blackboard. Name of this document is
\"Relationship diagram for W3schools order pdf.\" 1) Write a query to show Customers\' Country
wise sales totals. Your query should show Customers\' Country name and the total sale value for
that Country 2) Write a query to show Product wise sales totals. Your query should Product
name and the total sale value for that Product. 3) Write a query to show the number of orders for
each shipper. Your query should show shipper name and the count of orders with the shipper. 4)
Write a query to show number of products in each product category. Your query should show
Category name and number of products in that category 5) Write a query that shows Customers\'
country wise customer count, and order count. Your query should show country name, total
number of customers from that country, and total number of orders from the customers of that
country 6) Write a query that shows the number of products supplied by each Supplier. Your
query should show Country name, supplier name and the count of products supplied by that
supplier. Note: Sale Price Orderdetails.Quantity Products.price (see an example in the class
slides deck) W3SCHOOLS SQL is located at http://www.w3schools.com/sql/default.asp
(Preferred browser is Chrome). On this page you will find a button called \"Try it yourself\".
Click on that button. You will be redirected to a page where you see a list of tables on the right
side of the page. It is highly recommended to click \'Restore Database\' button on this page
during every session. The page contains a box where you can type in an SQL statement
involving the listed tables. You type in your SQL statement in that box and click on \"Run
SQL\'\' button. The results will be displayed if your SQL statement is syntactically correct.
Solution
1. SELECT Customers.Country, SUM(OrderDetails.Quantity * Products.Price) AS Total_Sale
FROM Customers
LEFT JOIN Orders ON Customers.CustomerID=Orders.CustomerID
LEFT JOIN OrderDetails ON Orders.OrderId=OrderDetails.OrderId
LEFT JOIN Products ON OrderDetails.ProductId=Products.ProductId
Group BY Customers.Country;
2. SELECT Products.ProductName, SUM(OrderDetails.Quantity * Products.Price) AS
Total_Sale FROM Customers
LEFT JOIN Orders ON Customers.CustomerID=Orders.CustomerID
LEFT JOIN OrderDetails ON Orders.OrderId=OrderDetails.OrderId
LEFT JOIN Products ON OrderDetails.ProductId=Products.ProductId
Group BY Products.ProductName;
You can edit these query to get other results set..
So Far I have these two classes but I need help with my persontest c.pdfarihantgiftgallery
So Far I have these two classes but I need help with my persontest class:
The next step is to add method calls for the accessor methods after each input:
//Reading and updating values
System.out.print(\"\ Enter Person Name: \");
person1.setPersonName(sc.nextLine());
System.out.println(\"You entered: \" + person1.getPersonName());
Call the accessor function each time you ask for input, after capturing that input. Then repeat for
a second Person, only this time call the constructor that takes the student id as a parameter.
7 import java.util.Scanner;
8
9 class PersonTest
10 {
11 //Main method
12 public static void main(String args[])
13 {
14 Scanner sc = new Scanner(System.in);
15
16 //Creating object
17 Persons_Information person1 = new Persons_Information();
18
19 //Reading and updating values
20 System.out.print(\"\ Enter Person Name: \");
21 person1.setPersonName(sc.nextLine());
22
23 System.out.print(\"\ Enter Current Address: \");
24 person1.setCurrentAdress(sc.nextLine());
25
26 System.out.print(\"\ Enter Permanent Address: \");
27 person1.setpermanentAdress(sc.nextLine());
28
29 System.out.print(\"\ Enter ID number: \");
30 person1.setIdNumber(sc.nextInt());
31
32 sc.nextLine();
33
34 System.out.print(\"\ Enter Birth Date: \");
35 person1.setBirthDate(sc.nextLine());
36
37
38 System.out.print(\"\ Enter Person Age: \");
39 person1.setPersonAge(sc.nextInt());
40
41
42 System.out.print(\"\ Enter Entry Year: \");
43 person1.setEntryYear(sc.nextInt());
44
45
46 System.out.print(\"\ Enter Total Years: \");
47 person1.setTotalYears(sc.nextInt());
48
49 //Printing person 1 details
50 System.out.println(\"\ Person 1: \ \" + person1.toString());
51 }
52 }
Solution
Persons_Information.java
public class Persons_Information {
//Declaring instance variables
private String personName;
private String currentAdress;
private String permanentAdress;
private int idNumber;
private String birthDate;
private int personAge;
private int entryYear;
private int totalYears;
//Zero argumented constructor
public Persons_Information()
{
}
//Parameterized constructor
public Persons_Information(int idNumber) {
this.idNumber = idNumber;
}
//Getters and setters
public String getPersonName() {
return personName;
}
public void setPersonName(String personName) {
this.personName = personName;
}
public String getCurrentAdress() {
return currentAdress;
}
public void setCurrentAdress(String currentAdress) {
this.currentAdress = currentAdress;
}
public String getPermanentAdress() {
return permanentAdress;
}
public void setPermanentAdress(String permanentAdress) {
this.permanentAdress = permanentAdress;
}
public int getIdNumber() {
return idNumber;
}
public void setIdNumber(int idNumber) {
this.idNumber = idNumber;
}
public String getBirthDate() {
return birthDate;
}
public void setBirthDate(String birthDate) {
this.birthDate = birthDate;
}
public int getPersonAge() {
return personAge;
}
public void setPersonAge(int personAge) {
this.personAge = personAge;
}
public int getEntryYe.
operating system linux,ubuntu,Mac Geometri.pdfaquadreammail
//operating system linux,ubuntu,Mac
/*********************GeometricObject.java**********************/
public abstract class GeometricObject {
private String color = \"white\";
private boolean filled;
// default constructure
public GeometricObject() {
super();
// TODO Auto-generated constructor stub
}
// construct a Geometric Object
// parameterized constructure
public GeometricObject(String color, boolean filled) {
this.color = color;
this.filled = filled;
}
/** Getter method for color */
public String getColor() {
return color;
}
/** Setter method for color */
public void setColor(String color) {
this.color = color;
}
/**
* Getter method for filled. Since filled is boolean, so the gret method
* name is isFilled
*/
public boolean isFilled() {
return filled;
}
/** Setter method for filled */
public void setFilled(boolean filled) {
this.filled = filled;
}
/** Abstract method for FindArea */
public abstract double findArea();
/** Abstract method for findPerimeter */
public abstract double findPerimeter();
}
/*****************************Octagon.java**************/
public class Octagon extends GeometricObject implements Cloneable, Comparable {
private double side;
/** construct a Octagon with specified side */
public Octagon(double side) {
super();
this.side = side;
}
/** Implement the abstract method findArea in GeometricObject */
@Override
public double findArea() {
double area = (2 + 4 / Math.sqrt(2)) * side * side;
return area;
}
/** Implement the abstract method findArea in findPerimeter */
@Override
public double findPerimeter() {
double perimeter = 8 * side;
return perimeter;
}
/** Implement the compareTo method in Comparable interface */
@Override
public int compareTo(Object o) {
// TODO Auto-generated method stub
return 0;
}
public Object clone() throws CloneNotSupportedException {
return super.clone();
}
}
/*******************App.java*******************/
public class App {
public static void main(String[] args) {
Octagon a1 = new Octagon(5);//creating object of octagon
System.out.println(\"Area of a1 is \" + a1.findArea());
System.out.println(\"Perimeter of a1 is \" + a1.findPerimeter());
Object a2;
try {
a2 = a1.clone();
String result = (a1.compareTo(a2) == 0) ? \"a1 and its clone a2 have the same area\"
: \"a1 and its clone a2 have different areas\";
System.out.println(\"Compare a1 and its clone a2:\ \\t \" + result);
System.out.println(\"Hashcode of a1: \" + a1.hashCode());
System.out.println(\"Hashcode of a2: \" + a2.hashCode());
System.out.println(\"Displaying a1: \" + a1);
System.out.println(\"Displaying a2: \" + a2);
} catch (CloneNotSupportedException e) {
e.printStackTrace();
}
}
}
/*****************output***************/
gopal@gopal:~/Desktop/chegg$ javac GeometricObject.java
gopal@gopal:~/Desktop/chegg$ javac Octagon.java
gopal@gopal:~/Desktop/chegg$ javac App.java
gopal@gopal:~/Desktop/chegg$ java App
Area of a1 is 120.71067811865476
Perimeter of a1 is 40.0
Compare a1 and its clone a2:
a1 and its clone a2 have the same area
.
Listing.javaimport java.util.Scanner;public class Listing { .pdfAnkitchhabra28
Listing.java
import java.util.Scanner;
public class Listing {
//Declaring instance variables
private String name;
private int age;
//Default constructor
public Listing() {
name=\" \";
age=0;
}
//parameterized Constructor
public Listing(String name, int age) {
super();
this.name = name;
this.age = age;
}
//Getters and setters
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
public int getAge() {
return age;
}
public void setAge(int age) {
this.age = age;
}
//This input() method will take the inputs entered by the user.
public void input()
{
//Scanner Object is used to get the data entered by the user
Scanner sc=new Scanner(System.in);
//Getting the user name
System.out.print(\"Enter Name :\");
setName(sc.nextLine());
//Getting the Age
System.out.print(\"Enter Age :\");
setAge(sc.nextInt());
}
//This toString() method will displays the constents of the user.
@Override
public String toString() {
System.out.println(\"Name :\"+getName());
System.out.println(\"Name :\"+getAge());
return \"\";
}
}
_____________________________________________________________
Driver.java
public class Driver {
public static void main(String[] args) {
//Create an array of 3 Listing Objects
Listing listing[]=new Listing[3];
//Creating Listing Objects and populating into an Array
for(int i=0;i<3;i++)
{
listing[i]=new Listing();
System.out.println(\"Listing Object \"+(i+1)+\":\");
//Calling the input method which capture the data entered by the user
listing[i].input();
}
//Displaying the Listing objects in the Normal Order
System.out.println(\"Displaying the Listing Objects in the Normal Order ::\");
for(int i=0;i<3;i++)
{
System.out.println(\"Listing Object \"+(i+1)+\":\");
listing[i].toString();
System.out.println(\"_____________________\");
}
//Displaying the Listing objects in the Reverse Order
System.out.println(\"Displaying the Listing Objects in the Reverse Order ::\");
for(int i=2;i>=0;i--)
{
System.out.println(\"Listing Object \"+(i+1)+\":\");
listing[i].toString();
System.out.println(\"_____________________\");
}
}
}
_______________________________________________________
Output:
Listing Object 1:
Enter Name :Kane Williams
Enter Age :27
Listing Object 2:
Enter Name :John Mills
Enter Age :23
Listing Object 3:
Enter Name :Tim Rochey
Enter Age :22
Displaying the Listing Objects in the Normal Order ::
Listing Object 1:
Name :Kane Williams
Name :27
_____________________
Listing Object 2:
Name :John Mills
Name :23
_____________________
Listing Object 3:
Name :Tim Rochey
Name :22
_____________________
Displaying the Listing Objects in the Reverse Order ::
Listing Object 3:
Name :Tim Rochey
Name :22
_____________________
Listing Object 2:
Name :John Mills
Name :23
_____________________
Listing Object 1:
Name :Kane Williams
Name :27
_____________________
_____________________________________________Thank You
Solution
Listing.java
import java.util.Scanner;
public class Listing {
//Declaring instance variables
private String n.
Similar to @author public class Person{ String sname, .pdf (20)
You have to leave solids and liquids out of the equation. This lea.pdfaplolomedicalstoremr
You have to leave solids and liquids out of the equation.
This leaves only product B for the product, nothing for the reactants.
Initially there was no product B.
At equilibrium: you determine the molarity by multiplying 2.5% by (0.5M/10L)= .00125 =
which rounds to answer E) 1.3e-3
it was a trick question.
Solution
You have to leave solids and liquids out of the equation.
This leaves only product B for the product, nothing for the reactants.
Initially there was no product B.
At equilibrium: you determine the molarity by multiplying 2.5% by (0.5M/10L)= .00125 =
which rounds to answer E) 1.3e-3
it was a trick question..
This is the final code which meets your requirement.Than youCard.j.pdfaplolomedicalstoremr
This is the final code which meets your requirement.Than you
Card.java
import java.util.Random;
public class Card {
//declaring instance variables
private String suit;
private int face_value;
public static int count=52;
//Creating an instance of Random class reference
Random rand;
//Default Constructor
public Card() {
super();
//Passing random class object to the Random class reference
rand = new Random();
}
//Getters and setters
public String getSuit() {
return suit;
}
public void setSuit(String suit) {
this.suit = suit;
}
public int getFace_value() {
return face_value;
}
public void setFace_value(int face_value) {
this.face_value = face_value;
}
public int getCount() {
return count;
}
//This shuffle() method will shuffle the deck
public void shuffle()
{
//Picking a card from the deck randomly and find its face value and suit
this.face_value = 1 + rand.nextInt((9) + 1);
int suit_random_value = 1 + rand.nextInt((3) + 1);
if(suit_random_value==1)
{
this.suit=\"Clubs\";
}
else if(suit_random_value==2)
{
this.suit=\"hearts\";
}
else if(suit_random_value==3)
{
this.suit=\"Spades\";
}
else if(suit_random_value==4)
{
this.suit=\"diamonds\";
}
this.count=count-1;
}
}
________________________________________________________________________
DriverClass.java
public class DriverClass {
public static void main(String[] args) {
//creating an array which can hold 52 Card class Objects
Card c[]=new Card[52];
//Creating 52 card class objects and storing them into an array
for(int i=0;i<52;i++)
{
//Creating Card class Object
c[i]=new Card();
}
//Displaying each card face value and its suit.
for(int i=0;i<52;i++)
{
//Shuffling the deck before every card picking from the deck
c[i].shuffle();
//Displaying randomly picked card face value and its suit
System.out.println(c[i].getFace_value()+\" of \"+c[i].getSuit()+\" Cards remaining
\"+c[i].getCount());
}
}
}
_________________________________________________________________________
Output:
8 of diamonds
Cards remaining 51
4 of Clubs
Cards remaining 50
9 of Clubs
Cards remaining 49
7 of Spades
Cards remaining 48
9 of diamonds
Cards remaining 47
7 of diamonds
Cards remaining 46
4 of diamonds
Cards remaining 45
9 of Clubs
Cards remaining 44
5 of hearts
Cards remaining 43
7 of Spades
Cards remaining 42
10 of Clubs
Cards remaining 41
7 of diamonds
Cards remaining 40
8 of diamonds
Cards remaining 39
6 of hearts
Cards remaining 38
4 of hearts
Cards remaining 37
6 of Spades
Cards remaining 36
4 of Clubs
Cards remaining 35
3 of diamonds
Cards remaining 34
9 of diamonds
Cards remaining 33
3 of diamonds
Cards remaining 32
5 of Spades
Cards remaining 31
4 of Clubs
Cards remaining 30
3 of Spades
Cards remaining 29
6 of diamonds
Cards remaining 28
3 of hearts
Cards remaining 27
9 of hearts
Cards remaining 26
7 of hearts
Cards remaining 25
3 of hearts
Cards remaining 24
10 of Clubs
Cards remaining 23
2 of hearts
Cards remaining 22
9 of Clubs
Cards remaining 21
8 of diamonds
Cards remaining 20
8 of Clubs
Cards remaining 19
2 of h.
Statistics is the mathematical science involving the collection, ana.pdfaplolomedicalstoremr
Statistics is the mathematical science involving the collection, analysis and interpretation of data.
A number of specialties have evolved to apply statistical theory and methods to various
disciplines. Certain topics have \"statistical\" in their name but relate to manipulations of
probability distributions rather than to statistical analysis.
· Actuarial science is the discipline that applies mathematical and statistical methods to
assess risk in the insurance and financeindustries.
· Astrostatistics is the discipline that applies statistical analysis to the understanding of
astronomical data.
· Biostatistics is a branch of biology that studies biological phenomena and observations by
means of statistical analysis, and includes medical statistics.
· Business analytics is a rapidly developing business process that applies statistical methods
to data sets (often very large) to develop new insights and understanding of business
performance & opportunities
· Chemometrics is the science of relating measurements made on a chemical system or
process to the state of the system via application of mathematical or statistical methods.
· Demography is the statistical study of all populations. It can be a very general science that
can be applied to any kind of dynamic population, that is, one that changes over time or space.
· Econometrics is a branch of economics that applies statistical methods to the empirical
study of economic theories and relationships.
· Environmental statistics is the application of statistical methods to environmental science.
Weather, climate, air and water quality are included, as are studies of plant and animal
populations.
· Epidemiology is the study of factors affecting the health and illness of populations, and
serves as the foundation and logic of interventions made in the interest of public health and
preventive medicine.
· Geostatistics is a branch of geography that deals with the analysis of data from disciplines
such as petroleum geology, hydrogeology, hydrology, meteorology,oceanography, geochemistry,
geography.
· Machine Learning
· Operations research (or Operational Research) is an interdisciplinary branch of applied
mathematics and formal science that uses methods such as mathematical modeling, statistics, and
algorithms to arrive at optimal or near optimal solutions to complex problems.
· Population ecology is a sub-field of ecology that deals with the dynamics of species
populations and how these populations interact with the environment.
· Psychometric is the theory and technique of educational and psychological measurement
of knowledge, abilities, attitudes, and personality traits.
· Quality control reviews the factors involved in manufacturing and production; it can make
use of statistical sampling of product items to aid decisions in process control or in accepting
deliveries.
· Quantitative psychology is the science of statistically explaining and changing mental
processes and behaviors in humans.
· Reliabi.
Secondary phloemApples (Malus communis, M. pumila, & M. sylvestr.pdfaplolomedicalstoremr
Secondary phloem
Apples (Malus communis, M. pumila, & M. sylvestris), pears (Pyrus communis) and quince
(Cydonia oblonga) belong to the rose family (Rosaceae), and include literally hundreds of
cultivated varieties. In the apple, the original ancestral species is obscured by so many cultivated
variations throughout the centuries that some authors lump them all into one species, Malus
domestica. They all originated in western Asia (or Eurasia) and are characterized by fleshy fruits
called pomes. In the pome, a thick, fleshy hypanthium layer (also called the floral cup or calyx
tube) surrounds (and is fused with) the seed-bearing ovary or core. The sepals, petals and
stamens arise from the rim of the hypanthium. Since the ovary is situated below the attachment
of the sepals, petals and stamens, it is termed \"inferior\" in technical plant taxonomy books. The
fleshy hypanthium of a rose (Rosa) surrounds a cluster of small one-seeded achenes. Since the
achenes represent separate ripened ovaries all derived from a single flower, the entire structure
(called a rose hip) can be considered an aggregate fruit or etaerio. Rose hips are eaten raw and
are ground up as a supplemental source of vitamin C (ascorbic acid).
Bing cherries (Prunus avium) showing the long stalk (pedicel) and fleshy drupe containng a hard,
stony, seed-bearing endocarp. Sweet cherries such as these are usually considered to belong to P.
avium, while sour cherries belong to the P. cerasus group. There are literally hundreds of
varieties of cherries. Maraschino cherries are made from sweet cherries which have been
bleached, deseeded, and soaked in a sugar solution to which red food coloring and flavoring have
been added. Maraschino cherries are commonly covered with chocolate, placed as a decorative
topping in ice cream sundies, and in mixed drinks.
The raspberry or hindberry is the edible fruit of a multitude of plant species in the genus Rubus,
most of which are in the subgenusIdaeobatus; the name also applies to these plants themselves.
Raspberries are perennial, with woody stems.
Raspberries are grown for the fresh fruit market and for commercial processing into individually
quick frozen (IQF) fruit, purée, juice, or as dried fruit used in a variety of grocery products.
Traditionally, raspberries were a mid-summer crop, but with new technology, cultivars, and
transportation, they can now be obtained year-round. Raspberries need ample sun and water for
optimal development. Raspberries thrive in well-drained soil with a pH of between 6 and 7 with
ample organic matter to assist in retaining water. While moisture is essential, wet and heavy soils
or excess irrigation can bring on Phytophthora root rot which is one of the most serious pest
problems facing red raspberry. As a cultivated plant in moist temperate regions, it is easy to grow
and has a tendency to spread unless pruned. Escaped raspberries frequently appear as garden
weeds, spread by seeds found in bird droppings.
An indiv.
probability that the trajectory falls between 1.2 and 1.4 =(1.4-1.2).pdfaplolomedicalstoremr
probability that the trajectory falls between 1.2 and 1.4 =(1.4-1.2)/(2.5-1) = 0.134
Solution
probability that the trajectory falls between 1.2 and 1.4 =(1.4-1.2)/(2.5-1) = 0.134.
Output:
Fibonacci till 20:
0
1
1
2
3
5
8
13
21
34
55
89
144
233
377
610
987
1597
2584
4181
Program:
import java.util.*;
import java.lang.*;
import java.io.*;
public class Main {
public static void main (String[] args) throws java.lang.Exception {
final int LIMIT = 20;
int[] fib = new int[LIMIT];
// init fib 0 and first val
fib[0] = 0;
fib[1] = 1;
for (int i = 2; i < LIMIT; ++i) {
fib[i] = fib[i - 1] + fib[i - 2];
}
System.out.println(\"Fibonacci till \" + LIMIT + \":\");
for (int i = 0; i < LIMIT; ++i) {
System.out.println(fib[i]);
}
}
}
Iterative solution is more efficient than recursive. The iterative solution do not compute the same
values again and again as recursive solution. Also because we are not using recursion the os
stack is not used hence computation is faster.
Solution
Output:
Fibonacci till 20:
0
1
1
2
3
5
8
13
21
34
55
89
144
233
377
610
987
1597
2584
4181
Program:
import java.util.*;
import java.lang.*;
import java.io.*;
public class Main {
public static void main (String[] args) throws java.lang.Exception {
final int LIMIT = 20;
int[] fib = new int[LIMIT];
// init fib 0 and first val
fib[0] = 0;
fib[1] = 1;
for (int i = 2; i < LIMIT; ++i) {
fib[i] = fib[i - 1] + fib[i - 2];
}
System.out.println(\"Fibonacci till \" + LIMIT + \":\");
for (int i = 0; i < LIMIT; ++i) {
System.out.println(fib[i]);
}
}
}
Iterative solution is more efficient than recursive. The iterative solution do not compute the same
values again and again as recursive solution. Also because we are not using recursion the os
stack is not used hence computation is faster..
Matter is made up of electrically charge particle but the Constituen.pdfaplolomedicalstoremr
Matter is made up of electrically charge particle but the Constituents of objects have opposite
charges, adding up to electric neutrality overall. Think of it in this way that two bring two
nucleus very close together we need a lot of energy because when we talk about nucleus it\'s only
the +ve(protons) charge we are talking about. That is why the fusion of two atoms is very tough
task. But in case of atoms or molecules that are the smallest entity of matter that can individually
exist; it always contain equal number of proton and electron and hence are electrically neutral on
a whole. Atom being neutral on whole there no force on other atoms
Solution
Matter is made up of electrically charge particle but the Constituents of objects have opposite
charges, adding up to electric neutrality overall. Think of it in this way that two bring two
nucleus very close together we need a lot of energy because when we talk about nucleus it\'s only
the +ve(protons) charge we are talking about. That is why the fusion of two atoms is very tough
task. But in case of atoms or molecules that are the smallest entity of matter that can individually
exist; it always contain equal number of proton and electron and hence are electrically neutral on
a whole. Atom being neutral on whole there no force on other atoms.
JUnit is a Regression Testing Framework used by developers to implem.pdfaplolomedicalstoremr
JUnit is a Regression Testing Framework used by developers to implement unit testing in Java,
and accelerate programming speed and increase the quality of code. JUnit Framework can be
easily integrated with either of the following
Features of JUnit Test Framework
JUnit test framework provides the following important features
Fixtures
Fixtures is a fixed state of a set of objects used as a baseline for running tests. The purpose of a
test fixture is to ensure that there is a well-known and fixed environment in which tests are run so
that results are repeatable
Test Suites
A test suite bundles a few unit test cases and runs them together. In JUnit, both @RunWith and
@Suite annotation are used to run the suite test.
Test Runners
Test runner is used for executing the test cases. Here is an example that assumes the test class
TestJunit already exists.
JUnit Classes
JUnit classes are important classes, used in writing and testing JUnits. Some of the important
classes are
Assert Contains a set of assert methods.
TestCase Contains a test case that defines the fixture to run multiple tests.
TestResult Contains methods to collect the results of executing a test case.
Solution
JUnit is a Regression Testing Framework used by developers to implement unit testing in Java,
and accelerate programming speed and increase the quality of code. JUnit Framework can be
easily integrated with either of the following
Features of JUnit Test Framework
JUnit test framework provides the following important features
Fixtures
Fixtures is a fixed state of a set of objects used as a baseline for running tests. The purpose of a
test fixture is to ensure that there is a well-known and fixed environment in which tests are run so
that results are repeatable
Test Suites
A test suite bundles a few unit test cases and runs them together. In JUnit, both @RunWith and
@Suite annotation are used to run the suite test.
Test Runners
Test runner is used for executing the test cases. Here is an example that assumes the test class
TestJunit already exists.
JUnit Classes
JUnit classes are important classes, used in writing and testing JUnits. Some of the important
classes are
Assert Contains a set of assert methods.
TestCase Contains a test case that defines the fixture to run multiple tests.
TestResult Contains methods to collect the results of executing a test case..
Intitially take a graph sheet and plot the points and the whole figu.pdfaplolomedicalstoremr
Intitially take a graph sheet and plot the points and the whole figure as it is.
Next draw the velocity diagram.Due to technical issues, I am not able to upload the graphical
representation.
Apply corialis acceleration component at link 6.
Solution
Intitially take a graph sheet and plot the points and the whole figure as it is.
Next draw the velocity diagram.Due to technical issues, I am not able to upload the graphical
representation.
Apply corialis acceleration component at link 6..
Incapsula Enterprise is the best mitigation service provider with th.pdfaplolomedicalstoremr
Incapsula Enterprise is the best mitigation service provider with the gold award winner and the
other two with silver and bronze award are F5 Silverline DDOS Protection and Arbor Cloud
respectively
With DDoS attacks growing in complexity and size daily, you need a DDoS protection service
with a robust network and variety of mitigation techniques to thwart any attacks directed at your
site. We found that Incapsula Enterprise, F5 Silverline DDoS Protection and Arbor Cloud
offered the best protection.
Incapsula’s growing global network and scrubbing capacities equip it with the size needed to
prevent large-scale volumetric attacks,27 data centers are connected which are located all over
the world, the service is prepared for even the most advanced DDoS attacks. In addition to
enormous network capacity and a high number of data centers, Incapsula hosts a variety of
mitigation techniques that intercept application layer, volumetric and protocol attacks.
With the recent acquisition of Defense.net, F5 has adjusted its service to offer cloud-based
mitigation technique, on-site and hybrid deployment methods,both hardware and the cloud is
used, F5 Silverline Protection is equipped for sophisticated DDoS attacks. This service surpasses
Incapsula in scrubbing capacity, it provides 2TB of bandwidth to filter, clean and remove
infected traffic. While the service does not offer unlimited mitigation, this protection service can
be used on-demand or always on, customizing it to fit the needs of any company.
Third one comes Arbor Cloud which offers a large network and scrubbing capacity and have
1.14TB of bandwidth, this server prepare the system for specialised volumetric attacks.variety of
protection techniques are provided by this service including IP blocking, rate limiting, automatic
bot discernment and more. While the cloud-based mitigation techniques are impressive, Arbor is
known for its hardware. The service is in a unique position, it\'s hardware is the challenge for it\'s
competitors
similar mitigation techniques is provided by all DDOS mitigation service providers to keep an
eye on any attacks and constant monitoring, they differ in price, deployment methods and
network size.It is not necessary that bigger mean better, the services that offer larger networks
and more mitigation technologies allow for more customization that you employ the best
protection service for your IT infrastructure.
Solution
Incapsula Enterprise is the best mitigation service provider with the gold award winner and the
other two with silver and bronze award are F5 Silverline DDOS Protection and Arbor Cloud
respectively
With DDoS attacks growing in complexity and size daily, you need a DDoS protection service
with a robust network and variety of mitigation techniques to thwart any attacks directed at your
site. We found that Incapsula Enterprise, F5 Silverline DDoS Protection and Arbor Cloud
offered the best protection.
Incapsula’s growing global network and scrubbing capacit.
Go with the most obvious one first...Carboxylic Acids will have a.pdfaplolomedicalstoremr
Go with the most obvious one first...
Carboxylic Acids: will have a really broad and large absorption range in the 3500-2500cm-1 area
(aka. the \"valley of the acid\") as well as a carbonyl peak in the 1700cm-1 area. That would be
spectrum 4.
Alcohols:will also have a strong and broad absorption in the 3500-3000cm-1 region, but nowhere
near as broad as the acid. It just looks like a really fat absorption line, rather than a well...
Anyway, the characteristic spectrum for the alcohol is spectrum 5.
Amines:lucky for you, the amine given in this question is a primary amine. There\'s going to be
two N-H stretching peaks in the 3300cm-1 region. There\'s also no carbonyl on the structure
given, so there should be no C=O stretching at 1700cm-1.This is spectrum 3. Don\'t worry about
the small absorption in the 1500-1700cm-1 area.
Now for the fine details...
The ester and aldehyde spectra are pretty similar, but aldehydes absorb at around 2750cm-1. It\'s
not totally clear on the spectra in the question but it looks like there\'s a 2750cm-1 absorption in
spectrum 2, so I\'d say that spectrum 2 is the aldehyde, and spectrum 1 is the ester.
Summary:
Spectrum 1 = structure B
Spectrum 2 = structure E
Spectrum 3 = structure C
Spectrum 4 = structure D
Spectrum 5 = structure A
Solution
Go with the most obvious one first...
Carboxylic Acids: will have a really broad and large absorption range in the 3500-2500cm-1 area
(aka. the \"valley of the acid\") as well as a carbonyl peak in the 1700cm-1 area. That would be
spectrum 4.
Alcohols:will also have a strong and broad absorption in the 3500-3000cm-1 region, but nowhere
near as broad as the acid. It just looks like a really fat absorption line, rather than a well...
Anyway, the characteristic spectrum for the alcohol is spectrum 5.
Amines:lucky for you, the amine given in this question is a primary amine. There\'s going to be
two N-H stretching peaks in the 3300cm-1 region. There\'s also no carbonyl on the structure
given, so there should be no C=O stretching at 1700cm-1.This is spectrum 3. Don\'t worry about
the small absorption in the 1500-1700cm-1 area.
Now for the fine details...
The ester and aldehyde spectra are pretty similar, but aldehydes absorb at around 2750cm-1. It\'s
not totally clear on the spectra in the question but it looks like there\'s a 2750cm-1 absorption in
spectrum 2, so I\'d say that spectrum 2 is the aldehyde, and spectrum 1 is the ester.
Summary:
Spectrum 1 = structure B
Spectrum 2 = structure E
Spectrum 3 = structure C
Spectrum 4 = structure D
Spectrum 5 = structure A.
Flexible benefit plans gives employees a choice between qualified be.pdfaplolomedicalstoremr
Flexible benefit plans gives employees a choice between qualified benefits (non taxable) and
cash. An example of qualified benefits is medical plans. Flexible benefit plans includes health
insurance and retirement benefits.
The 2 main types of flexible benefit plans are cafeteria plans and flexible spending accounts.
Under the cafeteria plan, employees have the option of choosing from several different benefit
packages. Employees can select the option of receiving some or all of the employer\'s nontaxable
benefits or receiving cash or other taxable benefits.
The benefits offered under cafeteria plans are health and group insurance, medical
reimbursement schemes for non-insured expenses and vacation days.
Flexible spending accounts (FSA) is another prevalant flexible benefit plan. FSA is a tax
deferred savings account. These accounts are formed by employers and helps the employee in
meeting certain medical expenses that are not a part of employer\'s insurance plan.
Solution
Flexible benefit plans gives employees a choice between qualified benefits (non taxable) and
cash. An example of qualified benefits is medical plans. Flexible benefit plans includes health
insurance and retirement benefits.
The 2 main types of flexible benefit plans are cafeteria plans and flexible spending accounts.
Under the cafeteria plan, employees have the option of choosing from several different benefit
packages. Employees can select the option of receiving some or all of the employer\'s nontaxable
benefits or receiving cash or other taxable benefits.
The benefits offered under cafeteria plans are health and group insurance, medical
reimbursement schemes for non-insured expenses and vacation days.
Flexible spending accounts (FSA) is another prevalant flexible benefit plan. FSA is a tax
deferred savings account. These accounts are formed by employers and helps the employee in
meeting certain medical expenses that are not a part of employer\'s insurance plan..
EnvironmentLet assume the environment is a grid of colored tiles(.pdfaplolomedicalstoremr
Environment:
Let assume the environment is a grid of colored
tiles(WHITE,BLUE,GREEN,BLACK,YELLOW).Robot is standing on a tile.Every tile has
a(X,Y) Position
We use a function getTileColor(x,y) to know color of current tile(x,y position).
ALGORITHM:
TRESUREHUNT(x,y)
1. color=getColor(x,y)
2. IF color=YELLOW
3. Return \"tiles\"+x+y+\" Is a tresure\"
4. ELSE IF color=WHITE
5. TRESUREHUNT(x,y-1) // move to front tile by decrementing y by 1
6 ELSE IF color=BLUE
7. TRESUREHUNT(x-1,y) // move to left bydecrementing x by 1
8. ELSE IF color=GREEN
9. TRESUREHUNT(x+1,y) // move to right tile by incrementing x by 1
10. ELSE IF color=BLACK
11. TRESUREHUNT(x,y+2) // move to front tile by incrementint y by 2
12. ELSE
13. Return \"Unsucessfull\"
12.END iF
C++ CODE
//for simplicity i represent entite grid in a 2;D array .Each cell is viewed as a tile.It contains
arbitary color values,0-BLACK
//1-BLUE,2;GREEN,14;YELLOW,15-WHITE
//accordingly the x,y value is changed. if current cell(tile)=15(WHITE) robot moves to front tile.
// so x=x-1 and y=y
#include
#include
void tresurehunt(int x,int y);
int grid[][7]={ {1, 1, 1, 14,2, 0, 15},
{0, 1, 1, 1, 0, 0, 2},
{2, 2 ,1, 0, 15,14,1},
{15,15,14,0, 1, 2, 1},
{15,0, 0, 1, 2, 2, 14},
{14,14,14,15,0, 2, 2},
{15,15,15,1, 1, 2, 1}};
int main()
{
tresurehunt(4,4);
return 0;
}
void tresurehunt(int x,int y)
{
//int color=getpixel(x,y);
int color=grid[x][y];
if(color==YELLOW)
{
cout<<\"Tresure is in:\"<
Solution
Environment:
Let assume the environment is a grid of colored
tiles(WHITE,BLUE,GREEN,BLACK,YELLOW).Robot is standing on a tile.Every tile has
a(X,Y) Position
We use a function getTileColor(x,y) to know color of current tile(x,y position).
ALGORITHM:
TRESUREHUNT(x,y)
1. color=getColor(x,y)
2. IF color=YELLOW
3. Return \"tiles\"+x+y+\" Is a tresure\"
4. ELSE IF color=WHITE
5. TRESUREHUNT(x,y-1) // move to front tile by decrementing y by 1
6 ELSE IF color=BLUE
7. TRESUREHUNT(x-1,y) // move to left bydecrementing x by 1
8. ELSE IF color=GREEN
9. TRESUREHUNT(x+1,y) // move to right tile by incrementing x by 1
10. ELSE IF color=BLACK
11. TRESUREHUNT(x,y+2) // move to front tile by incrementint y by 2
12. ELSE
13. Return \"Unsucessfull\"
12.END iF
C++ CODE
//for simplicity i represent entite grid in a 2;D array .Each cell is viewed as a tile.It contains
arbitary color values,0-BLACK
//1-BLUE,2;GREEN,14;YELLOW,15-WHITE
//accordingly the x,y value is changed. if current cell(tile)=15(WHITE) robot moves to front tile.
// so x=x-1 and y=y
#include
#include
void tresurehunt(int x,int y);
int grid[][7]={ {1, 1, 1, 14,2, 0, 15},
{0, 1, 1, 1, 0, 0, 2},
{2, 2 ,1, 0, 15,14,1},
{15,15,14,0, 1, 2, 1},
{15,0, 0, 1, 2, 2, 14},
{14,14,14,15,0, 2, 2},
{15,15,15,1, 1, 2, 1}};
int main()
{
tresurehunt(4,4);
return 0;
}
void tresurehunt(int x,int y)
{
//int color=getpixel(x,y);
int color=grid[x][y];
if(color==YELLOW)
{
cout<<\"Tresure is in:\"<.
Classification of organisms is based upon a number of physical and p.pdfaplolomedicalstoremr
Classification of organisms is based upon a number of physical and physiological features. The
structure and organization of reproductive organs remains in important feature usually used to
distinguish organisms. Some of the features can be discussed as below:
1. Fruiting body: A very broad classification can be made on the basis whether the fruiting body
is present or not. Presence of a fleshy or modified cover around the seed is a characteristic
feature of angiosperms whereas a naked seed located directly above a vegetative structure of a
plant is a feature of gymnosperms.
2. Spores sacs: Spore releasing sacs are characteristic features found on the lower scales of the
leaf blades of lower and higher ferns. Their arrangement and mode of release determines the
nature, frequency and ease of sexual reproduction in these lower plants.
3. Pollens: Higher plants, including both angiosperms and gymnosperms utilize pollen grains for
sexual reproduction. The mode of transfer of pollen determines the geographical range of
pollination in plants. Sulphur shower is a critical example for sexual reproduction in pines
(gymnosperms) which distinguishes them from other trees.
4. Sporocarp: A sporocarp or a fruiting body is a bulging of the vegetative extension from the
main structure of a lower fungi which contains a group of cells which either follow meiotic
division or mitotic division and serve as the reproductive structures. Their growth and nature can
be monitored microscopically and the fungus can be thus classified appropriately. Some algae
also contain a unique localization and arrangement of haploid cells called spores which can be
present in singles or doublets and thus represent a very unique discrimination from other
organisms.
These, these set of information provide an insight into usability of features of a reproductive
structure for classification of organisms.
Solution
Classification of organisms is based upon a number of physical and physiological features. The
structure and organization of reproductive organs remains in important feature usually used to
distinguish organisms. Some of the features can be discussed as below:
1. Fruiting body: A very broad classification can be made on the basis whether the fruiting body
is present or not. Presence of a fleshy or modified cover around the seed is a characteristic
feature of angiosperms whereas a naked seed located directly above a vegetative structure of a
plant is a feature of gymnosperms.
2. Spores sacs: Spore releasing sacs are characteristic features found on the lower scales of the
leaf blades of lower and higher ferns. Their arrangement and mode of release determines the
nature, frequency and ease of sexual reproduction in these lower plants.
3. Pollens: Higher plants, including both angiosperms and gymnosperms utilize pollen grains for
sexual reproduction. The mode of transfer of pollen determines the geographical range of
pollination in plants. Sulphur shower is a critical example for.
Hypothesis Test for population variance If we have a sample fro.pdfaplolomedicalstoremr
Hypothesis Test for population variance
If we have a sample from an underlying normal distribution and variance ?
Solution
Hypothesis Test for population variance
If we have a sample from an underlying normal distribution and variance ?.
Model Attribute Check Company Auto PropertyCeline George
In Odoo, the multi-company feature allows you to manage multiple companies within a single Odoo database instance. Each company can have its own configurations while still sharing common resources such as products, customers, and suppliers.
The French Revolution, which began in 1789, was a period of radical social and political upheaval in France. It marked the decline of absolute monarchies, the rise of secular and democratic republics, and the eventual rise of Napoleon Bonaparte. This revolutionary period is crucial in understanding the transition from feudalism to modernity in Europe.
For more information, visit-www.vavaclasses.com
The Roman Empire A Historical Colossus.pdfkaushalkr1407
The Roman Empire, a vast and enduring power, stands as one of history's most remarkable civilizations, leaving an indelible imprint on the world. It emerged from the Roman Republic, transitioning into an imperial powerhouse under the leadership of Augustus Caesar in 27 BCE. This transformation marked the beginning of an era defined by unprecedented territorial expansion, architectural marvels, and profound cultural influence.
The empire's roots lie in the city of Rome, founded, according to legend, by Romulus in 753 BCE. Over centuries, Rome evolved from a small settlement to a formidable republic, characterized by a complex political system with elected officials and checks on power. However, internal strife, class conflicts, and military ambitions paved the way for the end of the Republic. Julius Caesar’s dictatorship and subsequent assassination in 44 BCE created a power vacuum, leading to a civil war. Octavian, later Augustus, emerged victorious, heralding the Roman Empire’s birth.
Under Augustus, the empire experienced the Pax Romana, a 200-year period of relative peace and stability. Augustus reformed the military, established efficient administrative systems, and initiated grand construction projects. The empire's borders expanded, encompassing territories from Britain to Egypt and from Spain to the Euphrates. Roman legions, renowned for their discipline and engineering prowess, secured and maintained these vast territories, building roads, fortifications, and cities that facilitated control and integration.
The Roman Empire’s society was hierarchical, with a rigid class system. At the top were the patricians, wealthy elites who held significant political power. Below them were the plebeians, free citizens with limited political influence, and the vast numbers of slaves who formed the backbone of the economy. The family unit was central, governed by the paterfamilias, the male head who held absolute authority.
Culturally, the Romans were eclectic, absorbing and adapting elements from the civilizations they encountered, particularly the Greeks. Roman art, literature, and philosophy reflected this synthesis, creating a rich cultural tapestry. Latin, the Roman language, became the lingua franca of the Western world, influencing numerous modern languages.
Roman architecture and engineering achievements were monumental. They perfected the arch, vault, and dome, constructing enduring structures like the Colosseum, Pantheon, and aqueducts. These engineering marvels not only showcased Roman ingenuity but also served practical purposes, from public entertainment to water supply.
Embracing GenAI - A Strategic ImperativePeter Windle
Artificial Intelligence (AI) technologies such as Generative AI, Image Generators and Large Language Models have had a dramatic impact on teaching, learning and assessment over the past 18 months. The most immediate threat AI posed was to Academic Integrity with Higher Education Institutes (HEIs) focusing their efforts on combating the use of GenAI in assessment. Guidelines were developed for staff and students, policies put in place too. Innovative educators have forged paths in the use of Generative AI for teaching, learning and assessments leading to pockets of transformation springing up across HEIs, often with little or no top-down guidance, support or direction.
This Gasta posits a strategic approach to integrating AI into HEIs to prepare staff, students and the curriculum for an evolving world and workplace. We will highlight the advantages of working with these technologies beyond the realm of teaching, learning and assessment by considering prompt engineering skills, industry impact, curriculum changes, and the need for staff upskilling. In contrast, not engaging strategically with Generative AI poses risks, including falling behind peers, missed opportunities and failing to ensure our graduates remain employable. The rapid evolution of AI technologies necessitates a proactive and strategic approach if we are to remain relevant.
Synthetic Fiber Construction in lab .pptxPavel ( NSTU)
Synthetic fiber production is a fascinating and complex field that blends chemistry, engineering, and environmental science. By understanding these aspects, students can gain a comprehensive view of synthetic fiber production, its impact on society and the environment, and the potential for future innovations. Synthetic fibers play a crucial role in modern society, impacting various aspects of daily life, industry, and the environment. ynthetic fibers are integral to modern life, offering a range of benefits from cost-effectiveness and versatility to innovative applications and performance characteristics. While they pose environmental challenges, ongoing research and development aim to create more sustainable and eco-friendly alternatives. Understanding the importance of synthetic fibers helps in appreciating their role in the economy, industry, and daily life, while also emphasizing the need for sustainable practices and innovation.
Instructions for Submissions thorugh G- Classroom.pptxJheel Barad
This presentation provides a briefing on how to upload submissions and documents in Google Classroom. It was prepared as part of an orientation for new Sainik School in-service teacher trainees. As a training officer, my goal is to ensure that you are comfortable and proficient with this essential tool for managing assignments and fostering student engagement.
Introduction to AI for Nonprofits with Tapp NetworkTechSoup
Dive into the world of AI! Experts Jon Hill and Tareq Monaur will guide you through AI's role in enhancing nonprofit websites and basic marketing strategies, making it easy to understand and apply.
Honest Reviews of Tim Han LMA Course Program.pptxtimhan337
Personal development courses are widely available today, with each one promising life-changing outcomes. Tim Han’s Life Mastery Achievers (LMA) Course has drawn a lot of interest. In addition to offering my frank assessment of Success Insider’s LMA Course, this piece examines the course’s effects via a variety of Tim Han LMA course reviews and Success Insider comments.
1. /**
* @author
*
*/
public class Person
{
String sname, iname;
int fid, sid;
}
/**
* @author
*
*/
public class Student extends Person
{
String sname;
int sid;
int no_of_credits, tot_grade_pts;
/**
* @param sname
* @param sid
*/
public Student(String sname, int sid)
{
this.sname = sname;
this.sid = sid;
}
/**
* @return
*/
public String get_name()
{
return sname;
}
public int get_sid()
2. {
return sid;
}
public boolean two_equal(int sid)
{
if ((this.sid) == sid)
return true;
else
return false;
}
public void set_credits(int credits)
{
no_of_credits = credits;
}
public int get_credits()
{
return no_of_credits;
}
public void set_tot_gpts(int gpts)
{
tot_grade_pts = gpts;
}
public int get_tgpts()
{
return tot_grade_pts;
}
public float get_GPA()
{
return ((tot_grade_pts) / (no_of_credits));
}
}
/**
* @author
*
*/
public class Instructor extends Person
4. int creg_code, max_students, no_of_students;
ArrayList reg_students = new ArrayList();
/**
* @param cname
* @param creg_code
* @param max_students
*/
Course(String cname, int creg_code, int max_students)
{
this.cname = cname;
this.creg_code = creg_code;
this.max_students = max_students;
}
/**
* @param instructor_name
*/
void set_instructor(String instructor_name)
{
this.instructor_name = instructor_name;
}
/**
* method to search student id
*
* @param sid
* @return
*/
public boolean search_student(int sid)
{
if (reg_students.contains(sid))
return true;
else
return false;
}
/**
* method to add student id
*
5. * @param sid
*/
public void add_student(int sid)
{
try {
if ((reg_students.size()) == max_students)
{
throw new MyException();
}
else
reg_students.add(sid);
}
catch (Exception e)
{
System.out.println("Course has maximum students");
}
}
/**
* method to remove student id
*
* @param sid
*/
public void rem_student(int sid)
{
try {
if (reg_students.contains(sid))
reg_students.remove(new Integer(sid));
else
throw new MyException();
} catch (Exception e)
{
System.out.println("NO STUDENT FOUND WITH THE GIVEN id");
}
}
}
/**
6. * @author
*
*/
public class MyException extends Exception
{
public MyException() {
// TODO Auto-generated constructor stub
super(" Invalid Data");
}
}
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
public class Registrar
{
/**
* @param args
* @throws NumberFormatException
* @throws IOException
*/
public static void main(String args[]) throws NumberFormatException,
IOException
{
Course c1 = new Course("default_course", 123, 10);
int ch, regcode, max_stu, sid;
String cname, sname;
BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
do {
System.out
.println(" 1. create a course 2. add a student 3. remove a student 4. exit");
System.out.print("Enter your choice: ");
ch = Integer.parseInt(br.readLine());
switch (ch)
{
case 1:
System.out.print("Enter course name:");
7. cname = br.readLine();
System.out.print("Eter registration code :");
regcode = Integer.parseInt(br.readLine());
System.out.print("Enter max students :");
max_stu = Integer.parseInt(br.readLine());
Course c = new Course(cname, regcode, max_stu);
break;
case 2:
System.out.print("Enter student name: ");
sname = br.readLine();
System.out.print("Enter id : ");
sid = Integer.parseInt(br.readLine());
c1.add_student(sid);
break;
case 3:
System.out.print("Enter student id: ");
sid = Integer.parseInt(br.readLine());
c1.rem_student(sid);
break;
}
} while (ch != 4);
}
}
OUTPUT:
1. create a course
2. add a student
3. remove a student
4. exit
Enter your choice: 1
Enter course name:computers
Eter registration code :1211
Enter max students :30
1. create a course
2. add a student
3. remove a student
4. exit
8. Enter your choice: 2
Enter student name: srinivas
Enter id : 1
1. create a course
2. add a student
3. remove a student
4. exit
Enter your choice: 2
Enter student name: rajesh
Enter id : 2
1. create a course
2. add a student
3. remove a student
4. exit
Enter your choice: 3
Enter student id: 1
1. create a course
2. add a student
3. remove a student
4. exit
Enter your choice: 4
NOTE:
DONT HAVE TIME TO IMPLEMENT SERIALIZATION THINGS
Solution
/**
* @author
*
*/
public class Person
{
String sname, iname;
int fid, sid;
}
/**
9. * @author
*
*/
public class Student extends Person
{
String sname;
int sid;
int no_of_credits, tot_grade_pts;
/**
* @param sname
* @param sid
*/
public Student(String sname, int sid)
{
this.sname = sname;
this.sid = sid;
}
/**
* @return
*/
public String get_name()
{
return sname;
}
public int get_sid()
{
return sid;
}
public boolean two_equal(int sid)
{
if ((this.sid) == sid)
return true;
else
return false;
}
public void set_credits(int credits)
10. {
no_of_credits = credits;
}
public int get_credits()
{
return no_of_credits;
}
public void set_tot_gpts(int gpts)
{
tot_grade_pts = gpts;
}
public int get_tgpts()
{
return tot_grade_pts;
}
public float get_GPA()
{
return ((tot_grade_pts) / (no_of_credits));
}
}
/**
* @author
*
*/
public class Instructor extends Person
{
String iname;
int fid;
String dept;
/**
* @param iname
* @param fid
*/
public Instructor(String iname, int fid)
{
this.iname = iname;
12. this.max_students = max_students;
}
/**
* @param instructor_name
*/
void set_instructor(String instructor_name)
{
this.instructor_name = instructor_name;
}
/**
* method to search student id
*
* @param sid
* @return
*/
public boolean search_student(int sid)
{
if (reg_students.contains(sid))
return true;
else
return false;
}
/**
* method to add student id
*
* @param sid
*/
public void add_student(int sid)
{
try {
if ((reg_students.size()) == max_students)
{
throw new MyException();
}
else
reg_students.add(sid);
13. }
catch (Exception e)
{
System.out.println("Course has maximum students");
}
}
/**
* method to remove student id
*
* @param sid
*/
public void rem_student(int sid)
{
try {
if (reg_students.contains(sid))
reg_students.remove(new Integer(sid));
else
throw new MyException();
} catch (Exception e)
{
System.out.println("NO STUDENT FOUND WITH THE GIVEN id");
}
}
}
/**
* @author
*
*/
public class MyException extends Exception
{
public MyException() {
// TODO Auto-generated constructor stub
super(" Invalid Data");
}
}
import java.io.BufferedReader;
14. import java.io.IOException;
import java.io.InputStreamReader;
public class Registrar
{
/**
* @param args
* @throws NumberFormatException
* @throws IOException
*/
public static void main(String args[]) throws NumberFormatException,
IOException
{
Course c1 = new Course("default_course", 123, 10);
int ch, regcode, max_stu, sid;
String cname, sname;
BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
do {
System.out
.println(" 1. create a course 2. add a student 3. remove a student 4. exit");
System.out.print("Enter your choice: ");
ch = Integer.parseInt(br.readLine());
switch (ch)
{
case 1:
System.out.print("Enter course name:");
cname = br.readLine();
System.out.print("Eter registration code :");
regcode = Integer.parseInt(br.readLine());
System.out.print("Enter max students :");
max_stu = Integer.parseInt(br.readLine());
Course c = new Course(cname, regcode, max_stu);
break;
case 2:
System.out.print("Enter student name: ");
sname = br.readLine();
System.out.print("Enter id : ");
15. sid = Integer.parseInt(br.readLine());
c1.add_student(sid);
break;
case 3:
System.out.print("Enter student id: ");
sid = Integer.parseInt(br.readLine());
c1.rem_student(sid);
break;
}
} while (ch != 4);
}
}
OUTPUT:
1. create a course
2. add a student
3. remove a student
4. exit
Enter your choice: 1
Enter course name:computers
Eter registration code :1211
Enter max students :30
1. create a course
2. add a student
3. remove a student
4. exit
Enter your choice: 2
Enter student name: srinivas
Enter id : 1
1. create a course
2. add a student
3. remove a student
4. exit
Enter your choice: 2
Enter student name: rajesh
Enter id : 2
1. create a course
16. 2. add a student
3. remove a student
4. exit
Enter your choice: 3
Enter student id: 1
1. create a course
2. add a student
3. remove a student
4. exit
Enter your choice: 4
NOTE:
DONT HAVE TIME TO IMPLEMENT SERIALIZATION THINGS