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
BaLLatris [955]
2 years ago
8

Write a program that simulates picking a card from a deck of 52 cards. Your program should display the rank (Ace, 2, 3, 4, 5, 6,

7, 8, 9, 10, Jack, Queen, King) and suit (Clubs, Diamonds, Hearts, Spades) of the card using python
Computers and Technology
1 answer:
Artyom0805 [142]2 years ago
7 0

Answer:

Explanation:

The following is a python function that has arrays with all the cards available and then uses random to choose a random card from the dictionary. Finally it prints out the card chosen...

import random

def choose_card():

   card = ["Ace", 2, 3, 4, 5, 6, 7, 8, 9, 10, 'Jack', 'Queen', 'King']

   symbols = ['Clubs', 'Diamonds', 'Hearts', 'Spades']

   chosen_card = str(card[random.randint(0, len(card))])

   symbols = symbols[random.randint(0, len(symbols))]

   print("Chosen Card: " + chosen_card + " of " + symbols)

You might be interested in
Read the four detective reports and the combined affidavit and warrant for the M57 Patents case. Write a one- to two-page paper
Fantom [35]

Answer:The 2009-M57-Patents scenario tracks the first four weeks of corporate history of the M57 Patents company. The company started operation on Friday, November 13th, 2009, and ceased operation on Saturday, December 12, 2009. As might be imagined in the business of outsourced patent searching, lots of other activities were going on at M57-Patents.

Two ways of working the scenario are as a disk forensics exercise (students are provided with disk images of all the systems as they were on the last day) and as a network forensics exercise (students are provided with all of the packets in and out of the corporate network). The scenario data can also be used to support computer forensics research, as the hard drive of each computer and each computer’s memory were imaged every day.

Explanation:

4 0
3 years ago
What is computer system ?​
Over [174]

Answer:

a system that is a computer

6 0
3 years ago
Read 2 more answers
A user has multiple web pages open and is using email. Which layer of the Transmission Control Protocol/Internet Protocol (TCP/I
Fudgin [204]

Answer:

This is the second question like this I've seen. They aren't the greatest.

Explanation:

The question is not good. The answer would be option a, Transport even though it doesn't make a whole lot of sense when you really go into detail.

It could also be option d, Application but I think they're going for the first.

6 0
2 years ago
Debate whether social networking is harmful or helpful to society.
Dmitriy789 [7]

Answer:

I believe that Social Networking <em>IS </em>helpful to society, but, people use it for wrong stuff.

5 0
2 years ago
When first defining the cloud, NIST gave three service models, which can be viewed as nested service alternatives: software as a
irakobra [83]

Answer:

Infrastructure.

Explanation:

In Computer science, Cloud computing can be defined as a type of computing that requires shared computing resources such as cloud storage (data storage), servers, computer power, and software over the internet rather than local servers and hard drives. It offers individuals and businesses a fast, effective and efficient way of providing services.

Simply stated, Cloud computing are services or programs located on the Internet, they are usually remote resources making use of cloud storage.

When first defining the cloud, National Institute of Standards and Technology (NIST) gave three (3) service models, which can be viewed as nested service alternatives;

1. Software as a Service (SaaS).

2. Platform as a Service (PaaS)

3. Infrastructure as a Service (IaaS).

According to NIST, the five (5) characteristics of a cloud computing service are;

1. On-demand self-service .

2. Broad network access .

3. Resource pooling .

4. Rapid elasticity .

5. Measured service.

Additionally, the cloud service can either be deployed as private, public, hybrid or community service.

6 0
3 years ago
Other questions:
  • Type the correct answer in the box spell all words correctly
    8·1 answer
  • If Johanna wants to label the x- and y-axes in Excel she should click Layout, then what?
    12·1 answer
  • Write the include directive that allows use of the function headers in the file myFuncs.h.
    13·1 answer
  • If you wanted to have wireless connectivity in your home or​ apartment, you would need a​ _________________ to move packets of d
    11·1 answer
  • Which wildcard characters will return a single character when using the Find dialog box?
    6·2 answers
  • Whois the person start programming​
    13·1 answer
  • In Java:
    15·1 answer
  • 5. The command to add new layout to the slide is present in<br>tab.​
    15·1 answer
  • One problem with _______ is that often many copies of the same document are made. <br><br>HELPPP ​
    11·1 answer
  • The output of a computer can be seen on ( monitor, keyboard or mouse )​
    5·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!