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
BlackZzzverrR [31]
3 years ago
11

Write a function "nonRepeatings" that takes a string "s3" and returns the non-repeating characters in this string. Sample Input

s3 = "aaazzzdcccrttt" Sample Output The non-repeating characters are; d ryou are suppose to use for loops to go throw and return a dictionary of non repeating letters.
Computers and Technology
1 answer:
Furkat [3]3 years ago
6 0

Answer:

def nonRepeatings(s3):

   non = []

   letter_dictionary = {}

   for l in s3:

       if l in letter_dictionary:

           letter_dictionary[l] += 1

       else:

           letter_dictionary[l] = 1

   for c in letter_dictionary:

       if letter_dictionary[c] == 1:

           non.append(c)

   

   return non

Explanation:

- Declare an empty list and a dictionary

- Initialize a for loop that iterates through the given string s3

Inside the loop:

- If a character in the string is in the dictionary, increment its count by 1. If not, add it to the dictionary

When the first loop is done, initialize another for loop that iterates through the dictionary.

- Inside the loop, check if any character has a value of 1, put it to the non.

- Finally, return the non

You might be interested in
what will happen to the contents of the destination ell if you copy the contents of the source cell into the destination cell
DochEvi [55]

Answer:

It's content will be replaced with a content from the source cell.

7 0
2 years ago
Complete the statement below with the correct term.
g100num [7]

Answer:

boot disk

Explanation:

This disk contains files required by the boot sequence as well as the operating system, which is loaded at the end of the startup process.

8 0
3 years ago
Research online the variety of web services (see pages 197-198) currently available to software developers. List three different
Mrrafil [7]

Answer:

  1. lastpass
  2. Hootsuite
  3. Microsoft azure

Explanation:

4 0
3 years ago
The file format is used for graphic files.
Vesna [10]

Answer:

.GIF

Explanation:

GIF or Graphics Interchange Format files are widely used for web graphics, because they are limited to only 256 colors, can allow for transparency, and can be animated. GIF files are typically small is size and are very portable.

8 0
2 years ago
Me podrian ayudar con esta pregunta...
tamaranim1 [39]
The answer is B , Hope this helps , I don’t speak Spanish but a little bit I understand , I’m sure that’s the correct answer answer
8 0
3 years ago
Read 2 more answers
Other questions:
  • If you purchase a software suite for personal use, you can install the software how many times on how many different machines?
    6·1 answer
  • Eugene wants to indent a paragraph, but the ruler is not present. Which tabs could Eugene use in order to accomplish his goal?
    14·1 answer
  • identify at least three additional ethical responsibilities expected from a computer professional. In brief, explain each respon
    11·1 answer
  • What is the purpose of a Post Mortem Review? (5 points)
    5·1 answer
  • Why do we need to make a plan before actions?
    7·1 answer
  • What is the plan to make optimum usage of available spaces?
    15·1 answer
  • Compiler is an example of​
    5·1 answer
  • How to beat level 50 in give up robot 2
    5·1 answer
  • Refers to the capacity to form bonds with particular
    11·2 answers
  • Some hackers are skillful computer operators, but others are younger inexperienced people who experienced hackers refer to as?
    13·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!