Skip to content

my-courses.net

Python Courses & Exercises

Facebook Twitter Google Plus Linkedin Instagram YouTube Pinterest Tumblr VK Email RSS
  • Home
  • Python Courses
  • Python Exercises
  • Computer Glossary
  • Register

Month: August 2021

Solution Exercise 63: python algorithm which determines the list of words containing at least two vowels

August 31, 2021YOUNES DERFOUFIPython-ExercisesLeave a comment

Exercise 63 Write a program in python allowing to extract from a list of strings, the list of strings containing at least two vowels. Example if L = ["Java", "Python", "Dart", "MySql"] , the program returns the list ["Java", "Python"] . Solution #coding: utf-8def vowel (L): # initialization of the list of words containing at…

How To Use A Global Variable

August 20, 2021YOUNES DERFOUFISource CodeLeave a comment

my_globvar = 0def change_globvar(): global my_globvar # Needed to modify m_globvar my_globvar = 1 # we can change value of global variable change_globvar() print(my_globvar) Younes Derfoufimy-courses.net

How To Convert A Python Variable Type

August 20, 2021YOUNES DERFOUFISource CodeLeave a comment

x = 10print(type(x))// type intx = float(x) print(type(x))// flot type Younes Derfoufimy-courses.net

How To Get A Python Variable Type

August 20, 2021YOUNES DERFOUFISource CodeLeave a comment

x = 5print (type (x)) # x is of type intx = "Hello World"print (type (x)) # x is now of type string Younes Derfoufimy-courses.net

Search

Recent Posts

  • Solution Exercise 26: python algorithm to find all word beginning with the letter 'a'
  • Solution Exercise 25: python algorithm to reverse a given string
  • Solution Exercise 24: python program to check whether a word is palindrome or not
  • Solution Exercise 23: Python algorithm that extract the file extension
  • Solution Exercise 22: python algorithm that extract the first word in given text

Facebook Group

UserOnline

4 Users Online

Log In

3 × 1 =

  • Register
  • Lost your password?
© 2023 my-courses.net | Wordpress_Theme: Blogghiamo by CrestaProject.          CopyrightFrance.com