Given an input integer x for a math function defined by y = 3*(x^2) + 5 (three multiplied by the square of x plus five). The variable y...
Exercises
Given three variables called first, second and third. If third is less than the difference of first and second, then return third....
Given three integer variables called first, second and third, if second is less than first, return false. Otherwise, check if third lies...
Given two string variables called first and second. Write code that concatenates two strings and stores the result in the variable called...
Given three integers named first, second and third, write code that finds the average of the three numbers and that stores the result in...
Given a decimal number called input
, calculate the cube of this number. Store the result in the decimal variable called myCube
.
Below is some code your co-worker implemented, but they're asking you for help because it's not working the way they want it to.
The code...
You notice some co-worker's code is both not working and is overly complicated.
The code should act in the following way:
- if value is ...
Below is some code your co-worker implemented, but they're asking you for help because it's not working the way they want it to.
The code...
Below is some code your co-worker tried again to implement letter grade code, but it is still not working the way they want.
The code ...
For the question below, assume the following implementation of a Person class:
public class Person { private int age; private String...
For the question below, assume the following implementation of a Person class:
public class Person { private int age; private String...
For the question below, assume the following implementation of a Person class:
public class Person { private int age; private String...
For the question below, assume the following implementation of an Employee class:
class Employee { String name; public Employee(String ...
Given an integer called value
and an array of three integers called list
, the boolean found
should be true
if value
is is within list
one...
We want to count how many times we walked the family dog in a week. Provided an array of seven integers, representing how many times the...
We want to create a vector of strings, where each element represents a single ingredient so that if we need multiple of that ingredient,...
Given a vector of integers called numbers
, count how many negative numbers there are in the vector and return that count.
Write a function called isOdd
that receives one integer and returns true
if that number is odd (has non-zero remainder when dividing by...
Write a function called count
that receives (A) a string and (B) a character, and returns a count of how many times the character is...
Write a function called countVowels
that receives a string
and returns the count of how many vowels it has, including a
,e
,i
,o
, and u
and...
Write a function called makeExcited
that receives a char
and permanently changes the value of it so that it becomes an exclamation mark (...
For the question below, assume the following implementation of the Ball class
public class Ball{ private String color; private double...
For this question, assume the following implementation of the class Person and the following UML diagram
Person Class Implementation
...
For this question, assume the following implementation of the class Person and the following UML diagram
Person Class Implementation
...