1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
ExtremeBDS [4]
3 years ago
7

Define a method printFeetInchShort, with int parameters numFeet and numInches, that prints using ' and " shorthand. End with a n

ewline. Ex: printFeetInchShort(5, 8) prints: 5' 8" Hint: Use \" to print a double quote.

Computers and Technology
2 answers:
umka2103 [35]3 years ago
8 0

Answer:

public static void printFeetInchShort(int numFeet, int numInches){

      System.out.println(numFeet+"' "+numInches+"\"");

  }

Explanation:

Don't forget the brace!

worty [1.4K]3 years ago
4 0

Answer:

The program to this question as follows:

Program:

//header file

#include <iostream> //defining header file

using namespace std;

void printFeetInchShort(int numFeet,int numInches); //decalring method printFeetInchShort  

void printFeetInchShort(int numFeet,int numInches)//defining method printFeetInchShort

{

cout<<"height: "; // print message

cout<<numFeet<<"\'"<<""<<numInches<<"\""; //print value

}

int main() //defining main method

{

int numFeet, numInches; //defining integer variable

cout<<"Enter height feet: "; //print message

cin>>numFeet; //input value by user

cout<<"Enter height inches: "; //print message

cin>>numInches; //input value by user

printFeetInchShort(numFeet,numInches); //calling method printFeetInchShort    

return 0;

}

Output:

Enter height feet: 5

Enter height inches: 9

height: 5'9"

Explanation:

In the above C++ language program, first, a header file is included, that uses the basic function, in the next step, the "printFeetInchShort()" method is defined, in the method two integer variables passed as a parameter, inside this method a print function "cout" is used, that print user input value with single and double quote.

Then the main method is declared, inside this method two integer variables "numFeet and numInches" are defined, which is used to take input value by user and pass the value in "printFeetInchShort()" function parameter and call the function.

You might be interested in
How should I do it Please code for Java
andrew-mc [135]

Answer:

class Main {  

 public static void printPattern( int count, int... arr) {

     for (int i : arr) {

       for(int j=0; j<count; j++)

           System.out.printf("%d ", i);

       System.out.println();

     }

     System.out.println("------------------");

 }

 public static void main(String args[]) {

   printPattern(4, 1,2,4);

   printPattern(4, 2,3,4);

   printPattern(5, 5,4,3);

 }

}

Explanation:

Above is a compact implementation.

3 0
3 years ago
Given two input integers for an arrowhead and arrow body, print a right-facing arrow.
Zanzabum

Answer:

I don't know the language this is but here is something that will work for all lang

int num0 = 0;

int num1 = 0;

basically just print the ints in the right dimension

Explanation:

Sorry if I am wrong

I don't know much about this someone else's answer might be better than mine

3 0
3 years ago
Why was 1990 an important year regarding air quality?
fredd [130]

Explanation:

The United States created the Environmental Protection Agency. in some ways they have did that

4 0
3 years ago
Read 2 more answers
Which of the following is not a type of bank? (Everfi)
Zinaida [17]

Answer

Pay Day Lender

Explanation

A bank is a financial institution which is authorized by the government to accept deposits inform of cash or cheque from the public who are the customers, and it creates a credit. It saves money to for the customers and also provides security for the customers money. It also lends money to the customers as loan where they pay with interest within a given time. There are many types of banks which include credit unions, online banks,industrial, agricultural, retail banks and many others.

3 0
3 years ago
Read 2 more answers
How many possible mac addresses are there?
oksian1 [2.3K]
There are 6 octects ( 8 bit numbers ) in a MAC address, so there's 256^6 possible addresses.
6 0
3 years ago
Other questions:
  • Days of the week are represented as three-letter strings ("Mon", "Tue", "Wed", "Thu", "Fri", "Sat", "Sun"). Write a javaScript f
    14·1 answer
  • You just read an msds for acetic acid. based on what you read, what type of information is included in an msds sheet? record you
    7·1 answer
  • The Windows Group Policy feature provides __________ that govern the way Windows operates in enterprise environments. a. a centr
    8·1 answer
  • Please help! (I cant figure out)
    13·1 answer
  • The following algorithm computes the average height for a list of basketball player heights. Initialize a variable sum to 0. For
    11·2 answers
  • Computer software licensed under exclusive legal right of the copyright holder with the intent that the licensee is given the ri
    6·1 answer
  • How can learning opportunities for AI be extended to all
    6·1 answer
  • What is the difference between KE an PE
    8·1 answer
  • Fern has set up a computer network for the entire building. Unfortunately, the signal strength diminishes as it reaches toward t
    8·1 answer
  • Which of the following tabs on the Ribbon contains the commands for adding tables, pictures and shapes into a publication? Quest
    14·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!