Python Forum
simple if elif conditions in Python
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
simple if elif conditions in Python
#1
Hi There,
I am very much new to Python and to this forum. I am looking for code help.
I have a SAS code as below and I would like to replicate this in Python.
It would be great if you guys can assist me with this.

if Universtiy in ("name1","name2","name3") then Universtiy_Group='Go8 University';
else if University in ("name4","name5") then Universtiy_Group='Eligible Go8 University';
else Universtiy_Group="Others";

Kind regards,
CK
Reply


Messages In This Thread
simple if elif conditions in Python - by Chandan - Jan-08-2020, 02:00 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Python uppercase conversion conditions Jaypeng 7 3,045 Apr-29-2020, 11:24 AM
Last Post: jefsummers
  python ast if-elif confusion holyghost 3 3,165 Apr-19-2020, 12:36 PM
Last Post: pyzyx3qwerty
  How does while-If-elif-else-If loop conditions check run mrhopeedu 2 1,815 Oct-27-2019, 04:56 AM
Last Post: mrhopeedu
  Python coding mutiple elif's metro17 1 1,818 Aug-02-2019, 10:27 AM
Last Post: metulburr
  Whats the right way to refactor this Big if/elif/elif ? pitosalas 1 2,278 Jul-28-2019, 05:52 PM
Last Post: ichabod801

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020