Python Forum
How to write a code with İF function?
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How to write a code with İF function?
#2
Do you have to use "if"?

For your example, do you mean that 1234 would become 4123 or 4321?

What is your idea for getting hold of the digits in your four digit number? I would start with that part. If you can get the digits the rest is pretty easy.

You should post this under the Homework section.
Reply


Messages In This Thread
How to write a code with İF function? - by Aycaaxx - Nov-03-2020, 05:26 AM
RE: How to write a code with İF function? - by deanhystad - Nov-03-2020, 05:46 AM

Possibly Related Threads…
Thread Author Replies Views Last Post
  write code that resides in parent directory franklin97355 3 395 Apr-14-2024, 02:03 AM
Last Post: franklin97355
  needing some help to write some code for a game calculator rymdaksel 1 410 Jan-02-2024, 09:56 AM
Last Post: deanhystad
  Better way to write this function SephMon 1 814 Feb-08-2023, 10:05 PM
Last Post: Gribouillis
  write new function or change the old one to work "smartter? korenron 3 1,975 Aug-09-2021, 10:36 AM
Last Post: jamesaarr
  Putting code into a function breaks its functionality, though the code is identical! PCesarano 1 1,997 Apr-05-2021, 05:40 PM
Last Post: deanhystad
  How can I write a function with three parameters? MehmetAliKarabulut 1 2,426 Mar-04-2021, 10:47 PM
Last Post: Larz60+
  Hi Guys, please help me to write SAS macro parameter equivalent code in Python Manohar9589 2 2,593 Jun-14-2020, 05:07 PM
Last Post: Larz60+
  Print/write to file function tpolim008 4 2,787 Apr-01-2020, 07:59 PM
Last Post: tpolim008
  How to write test cases for a init function by Unit test in python? binhduonggttn 2 3,118 Feb-24-2020, 12:06 PM
Last Post: Larz60+
  write an integer to file using a function xvkxvo 4 3,185 Dec-10-2019, 11:27 PM
Last Post: xvkxvo

Forum Jump:

User Panel Messages

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