Skip to main content

Librairie simpliste de manipulation de tableaux a des fins d'enseignement de l'algorithmique

Project description

Librairie bibTableau

Cette librairie est destinée aux étudiants des UEs d'initiation à l'algorithmique de l'université de Bordeaux. Sa publication sur pypi vise à faciliter l'installation de la librairie par les étudiants en séance de travux pratiques.

Une librairie minimaliste

La librairie a un objectif pédagogique précis:

  • Faire en sorte que les étuiants manipule des tableaux comme si ceux-ci était typés et nécessitait la déclaration de leur taille.

La librarie ne contient que trois fonctions:

  • La fonction creerTableau crée un tableau de taille nombreElements
    • utilisation: creerTableau(10) ou creerTableau(10,-1)
def creerTableau(nombreElements,valeurInitiale=None ):
    return [valeurInitiale]*nombreElements
  • La fonction creerTableaualeatoire crée un tableau de nombreElements éléments tirés aléatoirement dans l'intervalle [borneInf, borneSup]
    • utilisation: creerTableauAleatoire(10) ou creerTableauAleatoire(10,-50,-10)
def creerTableauAleatoire(nombreElements,borneInf=-50, borneSup=50): 
    t = creerTableau(nombreElements)
    for i in range (nombreElements):
        t[i] = random.randint(borneInf,borneSup)
    return t
  • La fonction creerTableauMonotone crée un tableau de nombreElements éléments tirés aléatoirement dans l'intervalle [borneInf, borneSup]
    • si variation est positif (resp. négatif), le tableau est croissant (resp. décroissant)
    • utilisation: creerTableauMonotone(10) ou creerTableauMonotone(10,-1)
def creerTableauMonotone(nombreElements, variation = 1,borneInf=-1000, borneSup=1000):
     t = creerTableauAleatoire(nombreElements,borneInf,borneSup)
     var = variation < 0
     return sorted(t,reverse = var)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

bibtableau-0.1.1.tar.gz (1.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

bibtableau-0.1.1-py2.py3-none-any.whl (2.2 kB view details)

Uploaded Python 2Python 3

File details

Details for the file bibtableau-0.1.1.tar.gz.

File metadata

  • Download URL: bibtableau-0.1.1.tar.gz
  • Upload date:
  • Size: 1.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.7.1 CPython/3.11.5 Darwin/24.1.0

File hashes

Hashes for bibtableau-0.1.1.tar.gz
Algorithm Hash digest
SHA256 24cf627be483b57fa8c8834c78530a48edad3a426277ff7411f8dd99bd7e905b
MD5 0d11e01b7021f93b430b32438db8eb7b
BLAKE2b-256 b94d2f53a285327ffc970bf18df5403451f2bbaa4693d3fbd24d5b12309f9f29

See more details on using hashes here.

File details

Details for the file bibtableau-0.1.1-py2.py3-none-any.whl.

File metadata

  • Download URL: bibtableau-0.1.1-py2.py3-none-any.whl
  • Upload date:
  • Size: 2.2 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.7.1 CPython/3.11.5 Darwin/24.1.0

File hashes

Hashes for bibtableau-0.1.1-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 ae9e8abc7910727705c4caef9ec31fa606fda46757fc20af4de7e3462ebdc4eb
MD5 64be306c84d08f237f0f254bfce37a89
BLAKE2b-256 95bd1a52107e5734697c15113dea851d7cdc3a0c13b4ded362812ae7e990f808

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page