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
katen-ka-za [31]
3 years ago
13

Write a function called random_marks. random_marks should #take three parameters, all integers. It should return a #string. # #T

he first parameter represents how many apostrophes should #be in the string. The second parameter represents how many #quotation marks should be in the string. The third #parameter represen
Computers and Technology
1 answer:
Damm [24]3 years ago
4 0

Answer:

Explanation:

The following code is written in Java. It creates the function random_marks as requested. It uses three for loops to go concatenating the correct number of apostrophes, quotes, and pairs to the output string before returning it to the user. A test case was added in main and the output can be seen in the attached picture below.

class Brainly {

   public static void main(String[] args) {

       String output = random_marks(3,2,3);

       System.out.println(output);

   }

   public static String random_marks(int apostrophe, int quotes, int pairs) {

       String output = "";

       for (int x = 0; x < apostrophe; x++) {

           output += '\'';

       }

       for (int x = 0; x < quotes; x++) {

           output += '\"';

       }

       for (int x = 0; x < pairs; x++) {

           output += "\'\"";

       }

       return output;

   }

}

You might be interested in
True or false?
kenny6666 [7]

Answer:

True

Explanation:

An effective way of protecting programs against classic stack overflow attacks is to instrument the function entry and exit code to setup and then check its sack frame for any evidence of corruption.

5 0
3 years ago
Read 2 more answers
Suppose you have a string matching algorithm that can take in (linear)strings S and T and determine if S is a substring (contigu
Zielflug [23.3K]

Answer:

no seishsssssssssssssssssssss

8 0
3 years ago
Read 2 more answers
Gps receivers are commonly used by individuals to determine their geographic location while hiking and to obtain driving directi
soldier1979 [14.2K]
I think it is true also.
7 0
3 years ago
Which command group on the Slide Master tab is used to add headers, footers, and other placeholders to the slide
Vikki [24]

Answer:D

Explanation:

7 0
2 years ago
Read 2 more answers
How fast will a viral meme spread if it is not contained within 24 hours?
sveta [45]
Well a viral meme would spread very fast, it's a VIRAL meme which means it would spread faster than a normal meme. Even if it is contained in the 24 hour time period it would still become rather popular.
6 0
3 years ago
Read 2 more answers
Other questions:
  • A program that coaches you at each step in the process is said to have a(n)
    12·2 answers
  • Given the following code segment, what is output after "result = "? int x = 1, y = 1, z = 1; y = y + z; x = x + y; cout &lt;&lt;
    7·1 answer
  • Is a process in which an attacker attempts to acquire information about your network and system by social means, such as talking
    9·1 answer
  • Your computer is configured to obtain an ipv4 address and dns server address automatically. what utility will help you to find t
    12·1 answer
  • The two principal catalysts for the Information Age have been:________.
    15·1 answer
  • 1. Consider a direct-mapped cache that can accommodate 8Mbytes from a main memory, that uses a 32-bit address and 32-byte blocks
    5·1 answer
  • Complete the do-while loop to output every number form 0 to countLimit using printVal. Assume the user will only input a positiv
    9·1 answer
  • In Access, it is possible to have _______________ fields, that is, fields that can contain more than one value.
    9·1 answer
  • What are the five Ws?<br> (I don’t even know what this means)
    5·2 answers
  • At the heart of every computing device is a(n) _______________, which is usually a single, thin wafer of silicon and tiny transi
    12·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!