Social Icons

Friday, November 27, 2020

Python-courses-python-exercises

Exercise 92

Write a python program as a function which takes a string s as parameter and returns True if the string s contains at least one uppercase character and False otherwise.

Solution

def containsUpper(s):
    
     # define and initialize a variable which counts the number of capitals
     counter = 0
    
     # browse the characters in the string s
     for x in s:
          # increment the counter each time the character encountered is in uppercase
          if x.isupper ():
               counter = counter + 1
     if counter> 0:
          return True
     else:
          return False
# Example
print (containsUpper ("djangoFramework")) # prints True
print (containsUpper ("djangoframework")) # prints false


Younes Derfoufi
my-courses.net

Thursday, November 19, 2020

Python-courses-python-exercises-python-for-while

Exercise 89

Write a Python algorithm which determines the list of repeated charcters in given string. Example: if s = "Programming language", the algorithm returns the list:
['r', 'g', 'a', 'm', 'n']

Solution

# create a function to test if given character is repeated within a given string
def isRepeated(s,c):
    counter = 0
    for x in s:
        if x == c:
            counter = counter + 1
    if counter >= 2:
        return True
    else:
        return False
# create a function that returns the list of all repeated characters
def repeated(s):
    # initializing the list of all repeated characters
    listRepeated = []
    for x in s:
        if isRepeated(s , x) and x and x != " " and x not in listRepeated:
            listRepeated.append(x)
    return listRepeated

# Example
s = "programming language"
print("List of repeated characters in s: " , repeated(s)) 
# The output is : List of repeated characters in s:  ['r', 'g', 'a', 'm', 'n']


Younes Derfoufi
my-courses.net

Saturday, November 14, 2020

python-courses-python-exercises-python-tutorials-python-formation

What's Pthon ?
Python is a wellknown-reason programming language this is becoming ever extra popular for records science. businesses international are the use of Python to harvest insights from their records and advantage a competitive side. unlike different Python tutorials, this path specializes in Python in particular for data technological know-how. In our creation to Python route, you’ll study effective approaches to store and control facts, and useful records technology tools to start conducting your very own analyses. start DataCamp’s on line Python curriculum now.
Python, named after the British comedy institution Monty Python, is an interpreted, interactive, item-orientated programming language. Its flexibility lets in it to do many stuff, each massive and small. Python can be used to put in writing simple packages, however it also possesses the whole strength required to create complicated, massive-scale agency solutions. A number of the ways in which Python is used includes:
Python-courses-python-exercises-python-sets-python-inheritance

Exercise 93

Write a Python program which wrap a given string into a paragraph of given width Solution
import textwrap
def wrapText(s , w):
    return textwrap.fill(s,w)

# Example
s = "Python is open source programming language"
print(wrapText(s , 20))
"""
The out put is:
Python is open
source programming
language
"""


Younes Derfoufi
my-courses.net

Friday, November 13, 2020

features-Python-courses-python-exercises-python-oop

Exercise 91 ***

Write a python algorithm which determines the common words with maximum length of two strings text T1 and T2. Example if: T1 = "Python created by Guidorossum is open source programming language. Python was created on 1991" and T2 = "Python created by Guidorossum is the most popular programming language Guidorossum", the algorithm returns the list:
['Guidorossum', 'programming']

Solution

#creating a method which determines the list of common words in T1 and T2
def commonWords(T1 , T2):
    # converting the texts into lists
    listWords_in_T1 = T1.split()
    listWords_in_T2 = T2.split()

    # initializing the common words
    listCommon_words = []
    for word in listWords_in_T1 :
        if word in listWords_in_T2 and word not in listCommon_words:
            listCommon_words.append(word)
    return listCommon_words

# Creating a methode that determines the common word with maximum length
def commonMax(T1, T2):
    listCommon_words = commonWords(T1 , T2)
    # initializing the maximum length
    maxLength = 0
    for word in listCommon_words:
        if len(word) >= maxLength:
            maxLength = len(word)
            
    # searching the the common words of maximum length
    listCommonWordMax = []
    for word in listCommon_words:
        if len(word) == maxLength:
            listCommonWordMax.append(word)
    return listCommonWordMax

T1 = "Python created by Guidorossum is open source programming language. Python was created on 1991"
T2 = "Python created by Guidorossum is the most popular programming language Guidorossum"
print(commonMax(T1 , T2))
# The output is: ['Guidorossum', 'programming']


Younes Derfoufi
my-courses.net

Thursday, November 12, 2020

python-courses-python-exercises-python-tutorials-python-formation

Python is a fashionable-purpose built-interpreted, built-interactive, object-oriented, and high-degree programmbuilt-ing language. It turned builtintegrated created by way of Guido van Rossum built-inintegrated 1985- 1990. Like Perl, Python source code is likewise available under the GNU trendy Public License (GPL).
Python is an integratedterpreted, item-orientated, excessive-level programmintegratedg language with dynamic semantics developed by way of Guido van Rossum. It built-intointegrated at the start released integrated 1991. Designed to be easy as well asintegrated built-ing, the call “Python” is a nod to the British comedy built-institution Monty Python. Python has a popularity as a novice-friendly language, built-in Java as the most extensively used built-introductory language because it handles a whole lot of the complexity for the person, built-inintegrated built-inners to cognizance on completely built-ingraspbuiltintegrated programmbuilt-ing prbuiltintegrated built-in preference to mbuilt-inute builtintegrated.
Python is used for server-side netintegrated development, software program improvement, mathematics, and machbuiltintegrated scriptbuilt-ing, and is famous for fast utility development and as a scriptbuilt-ing or glue language to tie built-ing additives because of its high-level, data systems, dynamic typintegratedg, and dynamic bintegrateddintegratedg. program built-in fees are reduced with Python due to the without problems discovered syntax and emphasis on clarity. moreover, Python’s support of modules and applications enables modular applications and reuse of code.
Python is an open supply network language, so numerous built-inbuiltintegrated programmers are constantly built-inbuildbuiltintegrated libraries and capability for it.
Python-courses-neighborhood-Python-courses-bin-Python-courses-python-string

Exercise 87

Write a Python algorithm as a function which takes as parameter a tuple of two strings (s1, s2) and which returns the list of characters in s1 and not in s2. Example: if s1 = 'Python language' and s2 = 'Java Programming', the function returns the list:
['y', 't', 'h']

Solution

def differenceS1S2(s1 , s2):
    listDifference = []
    for x in s1:
        if x not in s2 and x not in listDifference:
            listDifference.append(x)
    return listDifference

s1 = "Python Programming" 
s2 = "Java Programming"
print(differenceS1S2(s1 , s2)) # the output is: ['y', 't', 'h']


Younes Derfoufi
my-courses.net

Wednesday, November 11, 2020

python-courses-python-exercises-python-tutorials-python-formation

What is Python?
Python is an object-orientated programming language created by way of Guido Rossum in 1989. it is preferably designed for fast prototyping of complex applications. It has interfaces to many OS system calls and libraries and is extensible to C or C++. Many huge businesses use the Python programming language consist of NASA, Google, YouTube, BitTorrent, and so forth.
The language has a simple syntax that allows low prices related to application renovation. It does not have one unique motive however can be used for more than one functions.
Python is a famous shape of programming to be used for scripting or glue language needed to connect existing programming elements. it may additionally be used for software development. It’s much like different programming codecs consisting of JavaScript. however the principal Java vs. Python difference is that it's miles much more likely to be used for “server-facet” scripting than JavaScript.
gaining knowledge of the Python-language or JavaScript comes right down to what sort of programming paintings you’re trying to do.
Python-courses-python-exercises-games-Python-courses-

Exercie 87

Write a Python algorithm as a function which takes as parameter a tuple of two strings (s1, s2) and which returns the list of common characters to s1 and s2.
Example: if s1 = 'Python language' and s2 = 'Java Programming', the function returns:
['P', 'o', 'n', ' ', 'a', 'g']

Solution

def commonCharacters(s1 , s2):
    listCommon = []
    for x in s1:
        if x in s2 and x not in listCommon:
            listCommon.append(x)
    return listCommon

s1 = "Python language" 
s2 = "Java Programming"
print(commonCharacters(s1 , s2)) # the output is: ['P', 'o', 'n', ' ', 'a', 'g']


Younes Derfoufi
my-courses.net
python-courses-python-exercises-python-tutorials-python-formation

Study the basics of the Python programmbuilt-ing language from your smartphone, anytime at your personal tempo and at the go with PyTutor.
construct your python competencies at the go along with this superb free app to built-ine Python Programmintegratedg. end up a Python programmbuilt-ing expert built-in built-inintegrated the python codbuilt-ing language. exambuiltintegrated Python is a ought to have app for all codbuilt-ing newbies or laptop technological know-how students to analyzeintegrated python programmbuilt-ing language every time they want and anywhere they want. whether you’re built-inintegrated for a python integratedterview or any exambuiltintegrated that requires python programmintegratedg knowledge, you can discover built-incredible content on thisintegrated programmintegratedg built-inintegrated app.

This superb Python Programmbuilt-ing gabuiltintegrated app has built-ing content built-ing of Python Programmintegratedg Tutorials, Python Programmbuilt-ing trabuiltintegrated, packages, Questions & solutions and all that you want to both built-in Python programmbuilt-ing basics or to turn out to be a Python programmintegratedg expert.

With an notable series of Python packages (code examples) with feedback, more than one questions and solutions, all your programmbuilt-ing integrated wishes are bundled built-in a integrated code built-ing to knowintegrated app.

Tuesday, November 10, 2020

Python-courses-download-Python-courses-s-Python-courses

Eercise 86 *

Write an algorithm in Python which determines the set of words that make up a text string s. Example if s = "Python is more power than Java", the algorithm returns the set:
{Python, is, more, power, than, Java}

Solution

# creation of a function which returns all the words that make up a text string s.
def wordSet (s):
     
     # initialize the set of words
     Set = set ({})
    
     # convert the string to a list
     ListWords = s.split ()
     # browse the words in the ListWords list
     for word in ListWords:
          Set.add (word)
     return Set
# Example
s = "Python is more power than Java"
print (wordSet (s))
# output: {'is', 'power', 'Java', 'more', 'Python', 'than'}


Younes Derfoufi
my-courses.net
features-Python-courses-python-exercises-python-oop

Exercise 85

Write a python algorithm which determines the set of all characters that make up a string s. Example if s = "Python programming", the algorithm returns the set:
{'p', 'i', '', 'r', 'o', 'm', 't', 'a', 'h', 'y', 'P', 'g' , 'n'}

Solution

# create a function which returns all the characters that make up a string s
def characterSet (s):
    # initialization of the set of characters
    Set = set ({})

    # iterate over all characters of the string s
    for x in s:
        Set.add (x)
    return Set

# Example
s = "Python programming"
print (characterSet (s))
# output: {'p', 'i', '', 'r', 'o', 'm', 't', 'a', 'h', 'y', 'P', 'g' , 'n'}


Younes Derfoufi
my-courses.net

Monday, November 9, 2020

python-courses-python-exercises-python-tutorials-python-formation

Python Programming

if you are trying to find an application to examine Python simple to develop without any programming expertise. you're at right location. study Python Programming in a greatly improved studying surroundings with more instructions, real exercise possibility, and community guide.
when potential programmers and coders begin getting to know languages, one of the maximum common questions is, what is the Python programming language? It’s a valid query, thinking about that many languages, such as Python, work collectively with different languages which will construct complicated web packages and sites. This brief advent to Python will assist any ability programmer recognize the language and why it’s useful.
Python is an open-source programming language that is high stage and works as a preferred cause language; it's far most customarily as compared to Ruby, JavaScript, and Scheme. What units Python apart from other programming languages is that it is easy to use, can be taught to a newbie, can be embedded into any utility, and can run on all modern-day working structures, inclusive of Mac, home windows, and Linux. it is also one of the maximum powerful languages a programmer can use and is about three and 5 times quicker to code than JavaScript and C++, respectively.

The Python program is a scripting language that may be used for prototype improvement, coding web sites and packages, processing snap shots, medical records, and extra. the program may be determined in motion on the Google seek engine, NASA, Disney, Pinterest, and extra. It changed into built for ease of use and pace and is much less complicated than Ruby and other similar object-orientated programming languages. due to the fact it's far open-sourced, this system has loved a reputation among developers and programmers, and it remains the bottom program for most websites in operation on the net today.
it-Python-courses-python-string--Python-courses-python-exercises

Exercise 84 *

Write a Python program as function that takes as parameter a string s and which returns the list of all repeated character in the string s. Example: if s = "python language", the fuction returns the list :
['n', 'a', 'g']

Solution

# create a function to test if given character is repeated within a given string
def isRepeated(s,c):
    counter = 0
    for x in s:
        if x == c:
            counter = counter + 1
    if counter >= 2:
        return True
    else:
        return False
# function which determines the list of all repeated characters
def listRepeated(s):
    repeated = []
    for x in s:
        if isRepeated(s,x) and x not in repeated:
            repeated.append(x)
        
    return repeated
          
# Example
s = "python language"
print("The list of repeated character is : " , listRepeated(s))
# The output is: 
# The list of repeated character is :  ['n', 'a', 'g']


Younes Derfoufi
my-courses.net
it-Python-courses-python-string--Python-courses-python-exercises

Exercise 83 *

Write a Python program as function that takes as parameter a string s and which returns the first repeated character in the string s. Example: if s = "django framework", the fuction returns the character 'a'

Solution

# create a function to test if given character is repeated within a given string
def isRepeated(s,c):
    counter = 0
    for x in s:
        if x == c:
            counter = counter + 1
    if counter >= 2:
        return True
    else:
        return False
# function which determines the first repeated character
def firstRepeated(s):
    repeated = ''
    for x in s:
        if isRepeated(s,x):
            repeated = x
            break
    return repeated
          
# Example
s = "django framework"
print("The first repeated character is : " , firstRepeated(s))
# The output is: 'The first repeated character is :  a'


Younes Derfoufi
my-courses.net

Sunday, November 8, 2020

python-courses-python-exercises-python-tutorials-python-formation

journey in the programming world.
How is Python used in the actual global?
Python’s design is based totally on the ideas of elegance, simplicity, and readability, which makes it a exquisite language for newbie developers. as it's clean to research, it's far now often the first desire in college-level programming instructions.
Python is one of the maximum popular languages for coding in the world.
most of the people of top U.S. faculties even use Python of their introductory coding classes: coaching college students to use Python to build simple games, parse records from web pages, or even conduct language processing!
still, many dad and mom and students alike frequently surprise — how is Python virtually utilized in agencies or diverse fields?
read directly to find out how Python powers nowadays’s leading industries, and performs a first-rate position in numerous computer technology disciplines. Why Python?
Python is a excessive-stage and general-reason coding language — meaning that it’s easier to recognize and may be used to remedy a variety of issues!

With its easy syntax, high clarity, usability throughout operating structures, Python is a precious language to each study and use for a selection of programs.
Python-courses-python-exercises-python--Python-courses-configure script-run-script

Exercise 82

Write a Python algorithm that remove all empty strings from list of strings Example:
If :
L = ["Python" , "" , "is" , "" , "the",  "most" , "", "used" , "programming", "language" , ""]
The output is:
['Python', 'is', 'the', 'most', 'used', 'programming', 'language']

Solution

def remove_empty_str(L):
    # initializing the list with no string
    newList = []
    
    # iterate over all element of the list L
    for word in L:
        if word != "":
            newList.append(word)
    return newList

# Example
L = ["Python" , "" , "is" , "" , "the",  "most" , "", "used" , "programming", "language" , ""]
print(remove_empty_str(L))
# Expected output is :
# ['Python', 'is', 'the', 'most', 'used', 'programming', 'language']


Younes Derfoufi
my-courses.net

Saturday, November 7, 2020

python-courses-python-exercises-python-tutorials-python-formation

Python is a dynamic, integrated and (bytecode-compiled) language. There aren't any built-in declarations of variables, parameters, capabilities, or strategies built-in source code. This makes the code quick and bendy, and you lose the compile-time type checkintegratedg of the supply code. Python tracks the styles of all values at runtime and flags code that doesn't make feel because it runs.
Python is an important programmbuilt-ing language to recognize — it is widely-utilized in fields like builtintegrated science, web improvement, software engbuilt-ineerintegratedg, sport improvement, automation. but what's the satisfactoryintegrated manner to analyzeintegrated Python? That may be hard and pabuilt-inful to discern out. I know that from built-in. one of the integrated that i found most built-inintegrated whilst i used to be masterbuiltintegrated Python was how regularly occurrbuiltintegrated all of the built-in assets have been. I desired to learn how to make web sites the usage ofintegrated Python, however it seemed like each gabuiltintegrated aid wanted me to spend lengthy, uninteresting, months on Python syntax earlier than I should even integrated dointegratedg what built-interested me.
An fantastic manner to see how Python code works is to run the Python built-interpreter built-in code right integratedto it. if you ever have a query like, "What takes place if I upload an integratedt to a listbuiltintegrated?" simply typbuilt-ing it integratedto the Python integratedterpreter is a quick and possiblyintegrated the nice way to look what takes place. (See under to peer what built-inely happens!)
exambuiltintegrated Python - AI with Python, Django, Flask, CherryPY, AI, ML with Compiler. you could study,

Friday, November 6, 2020

python-courses-python-exercises-python-tutorials-python-formation

About Python turtle

An animation that shows how the turtle is used to create images by way of combining forward and flip commands at the same time as a pen is touching the paper
A spiral drawn with an iterative turtle images set of rules
A turtle graphic pattern drawn with a Python program
The turtle has three attributes: a area, an orientation (or direction), and a pen. The pen, too, has attributes: shade, width, and on/off state.

The turtle actions with commands which can be relative to its personal function, along with "pass forward 10 areas" and "flip left ninety degrees". The pen carried by the turtle can also be managed, by means of enabling it, putting its coloration, or placing its width. A pupil could recognize (and expect and motive about) the turtle's movement through imagining what they would do in the event that they were the turtle. Seymour Papert referred to as this "frame syntonic" reasoning. A complete turtle images machine requires manipulate go with the flow, procedures, and recursion: many turtle drawing applications fall quick. From these building blocks you could build greater complicated shapes like squares, triangles, circles and other composite figures. The concept of turtle pics, for example is useful in a Lindenmayer machine for generating fractals.
Python-courses-python-exercises

Exercise 81

Write a Python algorithm as function which takes as parameter a string s and that return the dictionary whose keys are the words that making up the string s and whose values are the number of occurrences of words within the string Text s. Example: if s = "I use Python for datascience but I don't use Python for mobile", the algorithm returns the dictionary:
d = {'I': 2, 'use': 2, 'Python': 2, 'for': 2, 'datascience': 1, 'but': 1, "don't": 1, 'mobile': 1}

Solution

def wordOccurrence(s):
    
    # initializing the dictionary that we want to obtain
    d = dict({})
    
    # convrting the the string s into a list
    listWords = s.split()
    
    # iterate over all word in listWords 
    # and adding the number of occurrences of all word to the dictionary d
    for word in listWords:
        d[word] = listWords.count(word)
    
    return d

# Example
s = "I use Python for datascience but I don't use Python for mobile"
print(wordOccurrence(s))
# the output is : 
#{'I': 2, 'use': 2, 'Python': 2, 'for': 2, 'datascience': 1, 'but': 1, "don't": 1, 'mobile': 1}


Younes Derfoufi
my-courses.net

Thursday, November 5, 2020

python-courses-python-exercises-python-tutorials-python-formation

Python is a preferred-reason programming language that can be used on any modern-day pc running device. it can be used for processing text, numbers, pics, medical facts and just about anything else you would possibly store on a pc. it's far used each day within the operations of the Google seek engine, the video-sharing website YouTube, NASA and the new york stock exchange. those are but most of the places wherein Python performs crucial roles within the fulfillment of the enterprise, authorities, and non-earnings businesses; there are numerous others. Python is an interpreted language. this means that it isn't always converted to computer-readable code earlier than the program is administered but at runtime.

Tuesday, November 3, 2020

python-courses-python-exercises-python-tutorials-python-formation

Python is one of the maximum famous programming language advanced with the aid of Guido Van Rossum. Python is popular amongst developers because of its clear syntax and smooth code even for beginners. For those who just have marked their career in improvement, gaining knowledge of python may be very useful. they could leverage the Python Programming education, blogs, movies, modules, and hundreds of different resources to explore each nook of this trending language. as soon as completed, you may capable of carry out contemporary improvement operations consisting of GUI development, net designing, gadget admin paintings, complex economic transactions or calculations, records technological know-how, visualization, and this listing by no means ends in terms of the actual-international software of python programming.
The programming language you will be learning is Python. Python is an example of a excessive-level language; other excessive-degree languages you might have heard of are C++, php, Pascal, C#, and Java. As you might infer from the call high-level language, there are also low-stage languages, every so often referred to as device languages or assembly languages. Loosely talking, computers can simplest execute programs written in low-degree languages. as a result, applications written in a excessive-degree language must be translated into something extra suitable before they are able to run.

nearly all applications are written in high-level languages due to their blessings. it is an awful lot less difficult to program in a high-degree language so packages take less time to jot down, they're shorter and less complicated to read, and they are more likely to be correct. 2d, excessive-level languages are portable, which means that they could run on one of a kind sorts of computers with few or no modifications.

The engine that interprets and runs Python is referred to as the Python Interpreter: There are methods to use it: instantaneous mode and script mode.
research Python three Programming + learn Django Framework + examine Flask Framework + research system getting to know + research artificial Intelligence + examine Deep mastering + analyze Blockchain + research CherryPy + study MySQL + study Postgresql + study Python layout styles + learn Pytorch + Tensorflow guide and much extra,without advertisements. that is an in-depth manual to the maximum famous and maximum in-call for programming language Python.
subjects
learn Python 3

Python three introduction
what is New in Python 3
Python three overview
Python three environment Setup
learn Python 3 simple Syntax
analyze Python Variable kinds
learn Python basic Operators
examine Python decision Making
Python three Loops
Python 3 Numbers
research Python Strings
Python Lists
Python 3 Tuples
Python Dictionary
Python Date & Time
examine Python functions
Python three Modules
Python documents I/O
Python three Exceptions
Python three advanced Tutorials
study Python three classes/objects
research Python 3 Reg Expressions
research Python 3 CGI Programming
study Python three Database get admission to
Python 3 Networking
Python 3 Sending e mail
analyze Python three Multithreading
study Python 3 XML Processing
Python three GUI Programming
similarly Python 3 Extensions and Libraries

study Python Django

Django development review
Django surroundings Setup
developing our first mission
Apps existence Cycle
learn Django Admin Interface
growing views
analyze Django URL Mapping
analyze Django Template device
Django models
study Django web page Redirection
Django Sending E-mails
analyze Django established views
study Django shape Processing
research Django report uploading
Apache Setup
Cookies coping with
Django sessions
learn Django Caching
analyze Django feedback
Django RSS
research Django AJAX

-study Python Flask
Flask Programming overview
Flask surroundings
Flask software
learn Flask Routing
Variable rules
study Flask URL constructing
research Flask HTTP techniques
learn Flask Templates
research Flask Static files
Request item
study Flask Cookies
Flask classes
study Flask Redirect & mistakes
Message Flashing
learn Flask record uploading
study Flask Extensions
Flask Mail
Flask WTF
learn Flask SQLite
learn Flask SQLAlchemy
research Python device learning
system mastering (ML) is largely that area of pc technology with the help of which computer systems can provide sense to information in a good deal the equal way as people do. In easy words, ML is a type of synthetic intelligence that extract styles out of raw information via the usage of an algorithm or technique.

artificial Intelligence
synthetic intelligence is the intelligence confirmed by machines, in contrast to the intelligence displayed with the aid of people. This Python synthetic Intelligence educational covers the basic principles of various fields of synthetic intelligence like synthetic Neural Networks, herbal Language Processing, device gaining knowledge of, Deep mastering, Genetic algorithms and more.

analyze Python Deep gaining knowledge of
Python is a popular-purpose high-degree programming language this is widely utilized in facts science and for producing deep studying algorithms. This Python Deep studying tutorial introduces Python and its libraries like Numpy, Scipy, Pandas, Matplotlib; frameworks like Theano, TensorFlow, Keras.




my-courses.net

Monday, November 2, 2020

Python-courses-python-exercises-python-dictionary

Exercice 80

Write a python algorithm which determines the list of all common words to two text T1 and T2 without repetition. Example if:
T1 = "Python is open source programming language. Python was created on 1991"
and
T2 = "Python is the most popular programming language "
, the algorithm returns the liste
['Python', 'is', 'programming', 'language.']
( the word 'Python' must be added only once even if it shared twice)

Solution

def commonWords(T1 , T2):
    # converting the texts into lists
    listWords_in_T1 = T1.split()
    listWords_in_T2 = T2.split()
    print(listWords_in_T2)
    
    # initializing the common words
    listCommon_words = []
    for word in listWords_in_T1 :
        if word in listWords_in_T2 and word not in listCommon_words:
            listCommon_words.append(word)
    return listCommon_words

# Example
T1 = "Python is open source programming language. Python was created on 1991" 
T2 = "Python is the most popular programming language. "
print("The list of common words is : " , commonWords(T1 , T2))
# The output is :
# The list of common words is :  ['Python', 'is', 'programming', 'language.']


Younes Derfoufi
my-courses.net
python-courses-python-exercises-python-tutorials-python-formation

What is Python?
Python is a widespread-purpose interpreted, interactive, object-orientated, and high-level programming language.
Python academic app designed for software program programmers who need to research Python programming language from scratch and additionally best python educational for novices.
You ought to have a primary expertise of computer Programming terminologies. A simple expertise of any of the programming languages is a plus.
you can without difficulty examine python by the use of this app.
Python is a popular-cause programming language. if you see any survey on popular programming languages over the previous few years, Python continually comes on pinnacle of the demand chart each yr.
individuals who hate programming are tempted to exchange their minds via the simplicity of Python. most of the task listings have Python someplace as a part of the process description. allow us to see what makes Python so special on this decade and future. candidates and organizations upskill or reskill in Python irrespective of their qualifications, roles, and experience. pointless to mention, Python is very easy to examine. analyze Python like a pro download the app now and decorate your python capabilities to subsequent level.
these days Python is treated as first-class Language for records technology and device mastering
We essentially divided app into 4 important modules every has its kind of choices.
Python is a effective trendy-cause programming language. it's miles used in web improvement, statistics science, growing software program prototypes, and so forth. thankfully for beginners, Python has simple clean-to-use syntax. This makes Python an first-rate language to learn to software for beginners.
API improvement

There are a few excellent frameworks for API improvement with Python, among the ones, there are 2 favorites the various improvement community, Django and Flask (on Flask I wrote an editorial on why i love it so much and a base mission to installation your APIs)

The communication round API improvement went immediately into the path of internet frameworks, why? nicely… I don’t believe that you have to write your personal web server or framework while you want to cognizance on writing the code for your API.
a few people also argue the use of Python for internet improvement in wellknown, even though I normally don’t like to apply the ones frameworks for the the front-end part, and i favor to build front-ends the usage of React, or every other like VueJS or Ember for that subjects.

Sunday, November 1, 2020

Python-courses-python-exercises-python-dictionary

Exercise 78 **

Write a python algorithm which returns the list of all index where an occurrence occ is found within a given string s without using any predefined method as find(), rfind() , index()... The function returns the empty list [], if occ does not exist in s.
Example:
s = "Python is an interpreted language. Python is open source. Python is easy to learn"
occ = "Python" , the algorithm returns the list: [0, 35, 58]

Solution

def indexOfOccurrence(s , occ):
    # getting the length of the occurrence occ and the len of the string s 
    m = len(occ)
    n = len(s)

    # initializing the list of index
    listIndex = []
    # searching all indx of occurrence occ within the string s
    for i in range(0 , n-m):
        if s[i : m + i] == occ:
            listIndex.append(i)
    return listIndex

# Example:
s = "Python is an interpreted language. Python is open source. Python is easy to learn"
occ = "Python"
print(indexOfOccurrence(s, occ)) 
# The output is: [0, 35, 58]


Younes Derfoufi
my-courses.net

Python Exercises With Solutions

  1. Exercises on Python Strings
  2. Exercises on Python lists
  3. OOP Exercices with solutions
  4. Exercises on Python File I/O
  5. Python Dictionary Exercises
  6. Python Sets Exercises
  1. Python Arithmetic Exercises
  2. Equations & System Of Equations
  3. Polynomials and Functions
  4. Python Arithmetic Exercises 
  5. Numpy, Matplolib, Sympy , Scipy - Exercises
  6. Python Arithmetic Exercises
  1. Python GUI Tkinter Exercises



Younes Derfoufi

Category Of Mobile Courses

Actualités (644) Adsense (1) Affiliation (1) Algebraic Topology (2) Algorithmic (1) all-news (30) Android (5) Android App (8) Android app without code (4) Android Apps (256) Android Development (4) Android download (2) Android OS (3) AngularJS (1) Automata theory and formal language (5) Bootstrap CSS (1) C programming (5) Category and Functor (8) CMS (3) Computer Glossary (18) Create Mobile App With Ionic Framework (2) CSS (2) CSS-Cascading-Style-Sheets (4) Developpement Java (13) Differential Geometry (1) Django-Python-Framework (9) dropshiping (26) Earn Money by Internet (4) Emplois (23) Framework php (2) Fraud (2) HTML (7) Java For Beginners (10) Javascript (12) Kotlin Programming Language (8) Kotlin For Mobile Android (1) Linux Download (2) Marketing (5) Mobile (3) Mobile Courses (4) Mobile Marketing (4) MoneyGram (1) News (721) Node.js (5) Open Source (1) Photoshop (1) Protect Computer (1) Python (35) Python BeautifulSoup (1) Python For Data Science (2) Python PyQt (4) Python Reference (1) Python-Books (6) Python-DVD-Training (1) Python-Exercises (263) Python-Framework (1) Python-IDE (1) Python-Kivy-Framework (2) Python-Modules (1) Python-pdf (2) Python-pyQt (1) Référencement (2) Script PHP (2) Security (6) SEO (1) Snipping Tool: Faq (1) Social Networks (1) Source Code (1) Statistics With SPSS (2) Surveillance Software (1) Travail à domicile (6) Tutoriels php en vidéos (2) Tutoriels-MySql (6) tutoriels-php (19) Utilitaires (1) VPS (1) Web Hosting (1) Webcam (1) Webmarketing (11) Western Union (1) Windows 10 (1) Windows 7 (4) Windows 7 Faq (2) Windows 8 (1) Windows Accessories (1) Windows Download (8) Windows Drivers (1) Windows Fonts (1) Windows Power Shell (2) Windows Registry (2) Windows Security (18) Windows Software (2) Windows Spyware (2) Windows utilities (3) Windows Virus (2) Windows Vista (3) Windows Wireless (1) Windows xp (1) Wordpress (1)
 

Sample text

Sample Text

 
Blogger Templates