Skip to content
← Back to Community
HELP ME!
Profile icon
TheAlphaReturns

I have this list

ai_options["attack, heal"] abcd = random.choice(AI_options) print("The chosen was: {}".format(abcd))

This works fine and prints one of the options but what I want it to do is this:

import random ai_options["attack, heal"] abcd = random.choice(AI_options) if attack is chosen: do this elif heal is chosen: do this other thing

Does anybody have any solutions?? Solved By @Highwayman
answer:

import random ai_options["attack, heal"] abcd = random.choice(AI_options) if abcd == "attack" : do this elif abcd == "heal" : do this other thing
Answered by Highwayman [earned 5 cycles]
View Answer
Voters
Profile icon
TheAlphaReturns
Comments
hotnewtop
Profile icon
Highwayman

so, for you question;

How about

import random ai_options["attack, heal"] abcd = random.choice(AI_options) if abcd == "attack" : do this elif abcd == "heal" : do this other thing
Profile icon
TheAlphaReturns

Thanks @Highwayman this really worked!

Profile icon
yiyiwed

According to him , that cow also explains why the peasants didn't chase him away when the Swiss developers left . The peasants reminded the medical worker's ... fun trivia game

Profile icon
Petrikboss

Leading online casino 789bet 789betting betnow game center, online gambling, online slots, online games, online sports, a system to make money with a link to get wealth. 789bt

Profile icon
Petrikboss

web baccarat and slots that is going strong right now Mobile Baccarat You Can Profit From Anywhere Don't wait to come in to play baccarat. HubHengJing888 With many game formats. สมัคร คาสิโนออนไลน์

Profile icon
finnegan

I recently found many useful information in your website especially this blog page. Among the lots of comments on your articles. Thanks for sharing.加拿大簽證在線申請

Profile icon
yiyiwed

We've been helping businesses like yours stand out for over 10 years. We live uninjured, we silently accept it, even at the first moments of free arrows... เกมยิงปลา

Profile icon
Petrikboss

Contact us- LIstcry offer the variety of services Packers and movers, Home Shifting and Tempo and Truck Transportation in India. Packers and Movers Jaipur to Ajmer

Profile icon
bapexa

Additionally, the seat includes a built-in recline feature that allows you to adjust the angle of the seat to provide your child with a comfortable ride. The Chicco KeyFit 30 reviews is a great choice for parents looking for a safe and comfortable car seat for their children. chicco car sear

Profile icon
Petrikboss

A wholesome and holistic life- it is a craving for every and every person. Nevertheless the tense and busy time-schedules is just a large hurdle in the way. Aromatherapy can be a first selection regarding this. In that therapy, caressing body with rub fat is the trick of an excellent health and wellness. 서울출장마사지

Profile icon
bapexa

Allianz Packers and Movers Pvt. Ltd. is a leading Packing and Moving Company offers varied packing and moving services such as loading unloading service, ... Packers and Movers in Perambur Chennai

Profile icon
yiyiwed

또한 먹튀검증을 요청하기 전 토토매니저에서 보증하는 토토사이트를 이용해보시는 것도 좋은 방법입니다. 토토매니저에서 보장하는 토토사이트는 많은 보증금을 예치 받아 만약에 모를 먹튀에 대비하고 있습니다. 사설토토사이트

Profile icon
Petrikboss

Professional Course in Interior Design at Home Design Institute. A comprehensive training program for Interior Designers that covers everything from ... Homedesigninstitute.com

Profile icon
Umar-waqaswaqas

The trainings at the Accounting Academy are according to a program approved by the Ministry of Education and Science Accountingacademy.bg

Profile icon
Petrikboss

Be careful and always consult a trusted tarot, there are thousands on the internet, and rest assured, only a few know what they are doing, a friendly advice. We are waiting for you and thank you! Tarot in Burgos-Vidente in Burgos-Videncia in Burgos-Tarotista in Burgos consultar vidente en Burgos

Profile icon
finnegan

Excellent and very exciting site. Love to watch. Keep Rocking.Nft games

Profile icon
Petrikboss

An impressive share, I merely with all this onto a colleague who has been conducting a small analysis within this. And he the truth is bought me breakfast simply because I ran across it for him.. smile. So i want to reword that: Thnx for any treat! But yeah Thnkx for spending time to discuss this, I am strongly over it and enjoy reading much more about this topic. If it is possible, as you become expertise, would you mind updating your blog with additional details? It can be extremely great for me. Huge thumb up in this short article! FORMULÁŘ ŽÁDOSTI O VÍZA INDIE

Profile icon
shahzaib321

I really loved reading your blog. It was very well authored and easy to understand. Unlike other blogs I have read which are really not that good.Thanks alot! red bridesmaid dresses

Profile icon
Highwayman

Also as a side note: you can use
~~~~~~~~~ name_of_lamguage
CODE
~~~~~

To make the code be highlighted properly and everything in repl.it posts

Edit sorry one sec thing isn’t showing.

Profile icon
Highwayman
Profile icon
Highwayman

Post this in ask and you shall receive help. This is for sharing finished work, not asking questions
Edit: sorry not for sharing finished stuff, for sharing tutorials.