Using the provided recording and your knowledge from programming 1. Create a program in java that takes in an input from the user and checks whether it’s a number or a word. In case a number is entered the program should print the number to the power 3 and if a word is entered your program should split that word into 2.
For a business and enterprise users, network and data security is of utmost concern. To address this, there are a number of precautions that a WLAN user can adopt to prevent a network from hacker attacks, unauthorised access, and coparate espionage. Discuss various security measures /precautions that can be adopted in preventing these attacks.
Encryption to large extent can been adopted to restrict access to data/information only to intended receiver. With the use of well-labeled diagram, discuss various types of encryption and it's operations.
Sum of Non-Diagonals
As the creative content member of your newspaper company, you are given the task to publish a puzzle in your local newspaper. For a given MxM integer matrix, the task is to print the sum of all elements other than the diagonal elements,Both the diagonals are to be excluded.
Input
The first line of input is a positive integer M.
The next M lines of input contain M space-separated integers.
Output
The output is an integer that represents the sum of all the numbers in the matrix as mentioned above.
Sample Input1
3
4 1 3
2 5 6
1 2 3
Sample Output1
11
Sample Input2
5
1 2 2 3 3
4 4 5 6 7
9 8 7 6 5
9 2 3 8 8
-4 -2 -2 4 -7
Sample Output2
63
Write a program in Java that ask the user to enter their name, year of birth, and salary. The program must display thier name, age, and salary.
In the file RandomNumbers.java, write a class called RandomNumbers that has three integer instance variables: var1, var2, and var3. Write getter method for each variable: getVar1(), getVar2() and getVar3() and a RandomNumbers constructor that set the initial values of all the instance variables to 0. Then write the following 2 instance methods:
• setRandomValues( ) - accepts a low and high integer values as parameters, and sets var1, var2, and var3 to random numbers (generated using the Random class) within the range of the low and high input values (inclusive).
• getRandomValues( ) - prints out the 3 random numbers in the format: "Random values: var1 var2 var3"
Ex: If the input is:
15 20
the output may be:
Random values: 17 15 19
where 17, 15, 19 can be any random numbers within 15 and 20 (inclusive).
assign and print the roll number,phone number,and address of two students having name sam and john respectively by creating two objects of the class student
Write a program that produces the following output:
CCCCCCCCC ++ ++
CC ++ ++
CC ++++++++++++++ +++++++++++++++
CC ++++++++++++++ +++++++++++++++
CC ++ ++
CCCCCCCCC ++ ++
question: highest investor
ramsay is a stock broker , and N people have given him money to invest in stocks. some one may invest more money in an year. To than the person who invested most with ramsay he will send a gift at the end of the year . In case of a tie he will pick the person with the smallest lexicographic name.
Note:-
input :-
5
Harry 500
Andrew 300
Mary 1000
Jane 400
Tobey 1000
output:-
Mary 2
explanation output:- both tobey and mary have the biggest investment . as mary is smallest in lexicographic name than tobey and found at index 2 the output is "mary 2"
Using Visual Studio, create a simple program that will have the following features:
-ask the user to input the desired size of an array
-let the user input values to be saved in the declared array
-display all the values saved in the created array