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
Degger [83]
2 years ago
14

You will be given a string, containing both uppercase and lowercase alphabets(numbers are not allowed).

Computers and Technology
1 answer:
murzikaleks [220]2 years ago
6 0

Answer:

The Java code is given below with appropriate comments

Explanation:

import java.util.*;

class Main {

   static Set<String> set = new HashSet();

   static void printPerms(char ch[], int ind){

       //If end of string is reached, add it to set

       if(ind==ch.length){

           set.add(new String(ch));

           return;

       }

       for(int i=ind;i<ch.length;i++){

           //Only swap if lower case

           if((ch[i]>='a' && ch[i]<='z')&&((ch[ind]>='a' && ch[ind]<='z'))){

               char t  = ch[i];

               ch[i] = ch[ind];

               ch[ind] = t;

           }

           printPerms(ch,ind+1);

           if((ch[i]>='a' && ch[i]<='z')&&((ch[ind]>='a' && ch[ind]<='z'))){

               char t  = ch[i];

               ch[i] = ch[ind];

               ch[ind] = t;

           }

       }

   }

   public static void main(String[] args) {

       printPerms("aBbCc".toCharArray(),0);

       System.out.println(set);

   }

}

You might be interested in
__________ is a software-enabled technique that can change the hardcoded mac address to any mac address and thus overcome mac ad
lukranit [14]

MAC address spoofing is a software-enabled technique that can change the hardcoded mac address to any mac address and thus overcome mac address filtering.

<h3>What is MAC spoofing?</h3>

It should be noted that MAC spoofing simply means a technique for changing the factory assigned media access control to a network interface.

In this case, it is a a software-enabled technique that can change the hardcoded mac address to any mac address and thus overcome mac address filtering.

Learn more about spoofing on:

brainly.com/question/15179149

#SPJ12

6 0
2 years ago
Which functions are available in a Word table? Check all that apply.
dexar [7]
All of them are available
3 0
3 years ago
The National Archives is part of the federal government, which means that its content:
LuckyWell [14K]

Answer:

its A

Explanation:

the national archives is open to anyone who visits

3 0
3 years ago
"Demand" deals with which of the following groups? Select one: a. Buyers and Consumers b. Sellers and consumers c. Public and Pr
aksik [14]

Answer:

Demand deals with Sellers and Consumers.

Explanation:

Demand is an economics term that relates the requested interest of a consumer for a product to the need of production for the product by the seller.  Typically, demand goes hand-in-hand with supply.  Demand is the consumer's desire for the product, while supply is the amount of the product available.

In the case of this question, Sellers and Consumers fit the best out of the available options.

[a] Buyers and Consumers are the same thing

[c] Public and Private Sectors doesn't relate to demand

[d] Buyers and investors could be considered the same thing

Cheers.

5 0
3 years ago
Read 2 more answers
When visiting a museum Liam takes a photo of a painting with a smartphone which stores to image file. Which of the folllowing be
Maslowich

Answer: D. The phone can represent the photo in either digital or analog formats depending on the sampling technique that is used

Explanation:

Photos can either come out as analog or digital with digital formats having better overall quality overall. Digital photos are taken with digital cameras and so use electronic detectors while analog photography uses chemical processes.

The thing about photos taken by smartphones is that they can be represented as either digital or analog formats. It simply depends on the sampling techniques used.

5 0
3 years ago
Other questions:
  • You use_____ to view an XPS file
    10·1 answer
  • 1. What does it mean to say that a country’s land area is positively correlated with its population?
    12·2 answers
  • Which systems provide a single, cohesive platform
    11·1 answer
  • Write a program that determines the value of the coins in a jar and prints the total in dollars and cents. Read integer values t
    5·1 answer
  • Compared to other forms of communication, texting does not offer as many message cues.
    13·1 answer
  • Betty set up an account on a popular social networking website. she wants to know whether the privacy policy is effective for he
    14·1 answer
  • the increase and decrease font button and the change text colour button (as shown in the picture )are include in which group ?​
    6·1 answer
  • . In this project, how many times will the [Drive] block be repeated?
    15·1 answer
  • Question #7
    11·1 answer
  • The _________________ can be used to repair common causes of unbootable operating systems. It is based on the Windows Preinstall
    6·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!