print

Recherche

Voici les résultats de votre recherche.

notions_fondamentales @teaching:progappchim
77 Occurrences trouvées, Dernière modification :
le langage lui-même (if, elif, while, for, else, print,...). * Instruction d'**affectation** utilisant... hage de sa valeur ; Dans un programme, on utilise print. Le nombre de chiffres affichés peut varier (essayer par exemple "1/3". et "print (1/3.)") * **Typage automatique**. Attention au... e). Exemple : <code python> a = 0 if a > 0 : print("a est positif") print("car il est strictemen
numpy_simple @teaching:progappchim
47 Occurrences trouvées, Dernière modification :
n> import numpy as np a = np.array([[1,2],[3,4]]) print(a) print(a.dtype) </code> Sortie : <code> [[1 2] [3 4]] <type 'numpy.ndarray'> </code> <note tip>Pour d... de dimensions, les dimensions, le type de donnée print(a, a.ndim, a.shape, a.dtype) # avec des "floats" ... 6.6, 7.7, 8.8], [9.9, 0.2, 1.3, 2.4], ]) print(b, b.ndim, b.shape, b.dtype) # un tableau de zéro
elements_molecules @teaching:progappchim
39 Occurrences trouvées, Dernière modification :
(ELEMENTS) str(ELEMENTS[109]) ele = ELEMENTS['C'] print(ele.number, ele.symbol, ele.name, ele.eleconfig) print(ele.eleconfig_dict) print(sum(ele.mass for ele in ELEMENTS)) for ele in ELEMENTS: ele.validate() ele = repr(ele) print(ele, type(ele)) input("next ?") </code> <cod
presentation_principes @teaching:progappchim
31 Occurrences trouvées, Dernière modification :
15 >>> T=20+zero >>> P=n*R*T/V >>> atm=101325 >>> print(P,P/atm) 101555.51000000001 1.0022749568221072 >>... ro=6.02214199E23 >>> kboltzmann=1.3806505E-23 >>> print(Navogadro*kboltzmann) 8.31447334956 >>> 2**0.5 1.... > a=’bonjour’ >>> b="bonjour" >>> c=’Bonjour’ >>> print(a==b,a==c) True False >>> d="pâté123#" >>> print d pâté123# >>> é=d >>> long="""un deux ... dix""" >>> p
simulations_random_walks_codes @teaching:exos
21 Occurrences trouvées, Dernière modification :
ice : random choice of an element from a list print(choice(facepiece), choice(valeurpiece)) # ran... er number between 2 values (including limits) print(randint(0,10)) # imprime un nombre aléatoire entre 0 et 10 print(choice(range(0,11,1))) # same function, using ch... ate the generator for i in range(10): print(randint(1000,9999)) print(" ") </code> =====
solvents_data_class @teaching:progappchim
21 Occurrences trouvées, Dernière modification :
chemical formula def table(solvent_list): """print a table of all solvent attributes""" title_st... 1f %8.3f %8.2f %8.2f %8.2f %8.2f %-20s" print "-"*122 print title_str % ("Name", "Bp", "Mp", "Fp", "Density", "Dielect", "Ref. Ind", "Dipole", "H2... ormula") for solvent in solvent_list: print data_str % (solvent.name, solvent.bp, solvent.mp,
bioinformatic @teaching:progappchim
20 Occurrences trouvées, Dernière modification :
bases = ["A","C","G","T"] for base in bases: print(adn.count(base),) print() # Variante : for c in 'ACGT': print(adn.count(c),) print() # variante un peu moins lisible out = [] for c in 'ACGT': out.append(str(adn
suite_de_fibonacci-5 @teaching:progappchim
19 Occurrences trouvées, Dernière modification :
_item_logarithmic if __name__ == '__main__': print("Calculs exemples préliminaires...") i=int(in... . Donnez l'indice de l'élément souhaité ? ")) print ("Élément de la suite : "), if i <= 10: print(fibonacci_item_recursive(i)) print(fibonacci_item_from_list(i)) print(fibonacci_item(i)) pri
suite_de_fibonacci-3 @teaching:progappchim
16 Occurrences trouvées, Dernière modification :
. Donnez l'indice de l'élément souhaité ? ")) print("Élément de la suite : "), print(fibonacci_item(i)) print('Premiers éléments de la suite : ') for j in range(10): print(j,fibonacci_item(j)) </code> On peut compléter l
slices @teaching:progappchim
14 Occurrences trouvées, Dernière modification :
dices modulo len(seq...) """ a=[1,3,5,7,11,13,15] print "liste exemple : ",a b=a[1:4:1] print b # [3, 5, 7] print a[:5] # [1, 3, 5, 7, 11] print a[3:] # [7, 11, 13, 15] print a[-3:] # [11, 13, 15] # un élément sur 2 :
mendeleev @teaching:progappchim
13 Occurrences trouvées, Dernière modification :
for i in range(1,108)] for i in range(1,108): print(x[i-1], y[i-1]) plt.figure() plt.plot(x, y) plt.... aux valeurs en utilisant le symbole de l'élément print(element('Na').atomic_number) print(element('Na').melting_point) print(element('Na').boiling_point) # on peut aussi accéder aux mêmes valeu
pandas @teaching:progappchim
12 Occurrences trouvées, Dernière modification :
ames = [name.replace(' ', '_') for name in names] print(names) namesfr = [ 'Largeur des épaules', ... ] dict_names_fr = dict(zip(names, namesfr)) print(dict_names_fr) file_url = "http://linus.umons.ac... iter=' | ', engine='python', index_col=False) # print(df) # pandas misc # https://stackoverflow.com/qu... ing-with-complex-criteria-from-pandas-dataframe # print(df.columns) print(df.Age) print(df.dtypes) print(
suite_de_fibonacci @teaching:progappchim
12 Occurrences trouvées, Dernière modification :
ez... <code python fibonacci01-mauvais.py> a = 0 print(a) b = 1 print(b) c = a + b print(c) d = b + c print(d) e = c + d print(e) f = d + e print(f) g = e + f print(g) h = f + g print(h) i = g
suite_de_fibonacci-2 @teaching:progappchim
12 Occurrences trouvées, Dernière modification :
de_Fibonacci """ # élément d'indice 0 i = 0 a = 0 print(i,a) # élément d'indice 1 i = 1 b = 1 print(i,b) # structure de répétition pour appliquer la règle de r... oursuivre avec les mêmes instructions ??? print(i,c) #quelque chose de ce genre </code> Un peu ... de_Fibonacci """ # élément d'indice 0 i = 0 a = 0 print(i,a) # élément d'indice 1 i = 1 b = 1 print(i,b)
tkinter_gui_simple @teaching:progappchim
12 Occurrences trouvées, Dernière modification :
s nécessite aussi de transformer les instructions print en print().</note> <note warning>Certaines fonctionnalités de tkinter semblent poser parfois des problè... f-8 -*- from tkinter import * def action(): print("Yes, we can !") root = Tk() #w = Label(root, te... f-8 -*- from tkinter import * def action(): print("Yes, we can !") root = Tk() #w = Label(root, te
suite_de_fibonacci-4 @teaching:progappchim
10 Occurrences trouvées, Dernière modification :
scipy_simple @teaching:progappchim
9 Occurrences trouvées, Dernière modification :
poker_menteur @teaching:exos
8 Occurrences trouvées, Dernière modification :
math_nombres @teaching:progappchim
8 Occurrences trouvées, Dernière modification :
ph-3d @teaching:progappchim
8 Occurrences trouvées, Dernière modification :
algos_entiers @teaching:progappchim
7 Occurrences trouvées, Dernière modification :
sequences_brins_adn @teaching:exos
6 Occurrences trouvées, Dernière modification :
factorielle-2 @teaching:progappchim
6 Occurrences trouvées, Dernière modification :
matrices @teaching:progappchim
6 Occurrences trouvées, Dernière modification :
openbabel_jmol @teaching:progappchim
6 Occurrences trouvées, Dernière modification :
pieges @teaching:progappchim
6 Occurrences trouvées, Dernière modification :
testjs @teaching:progappchim
6 Occurrences trouvées, Dernière modification :
rotateur_biatomique @teaching:progappchim:matplotlib_gallery
6 Occurrences trouvées, Dernière modification :
initinfo @teaching
5 Occurrences trouvées, Dernière modification :
codes_astuces @floss:python
5 Occurrences trouvées, Dernière modification :
diffusion_chimique_1d @teaching:progappchim
5 Occurrences trouvées, Dernière modification :
factorielle-3 @teaching:progappchim
5 Occurrences trouvées, Dernière modification :
lennard-jones @teaching:progappchim
5 Occurrences trouvées, Dernière modification :
polynomes-7 @teaching:progappchim
5 Occurrences trouvées, Dernière modification :
ppoo @teaching:progappchim
5 Occurrences trouvées, Dernière modification :
desinformations @teaching
4 Occurrences trouvées, Dernière modification :
collection_namedtuple_exemple @teaching:progappchim
4 Occurrences trouvées, Dernière modification :
notions_avancees @teaching:progappchim
4 Occurrences trouvées, Dernière modification :
ph_courbe_titrage_2011 @teaching:progappchim
4 Occurrences trouvées, Dernière modification :
polynomes-bonus @teaching:progappchim
4 Occurrences trouvées, Dernière modification :
urllib @teaching:progappchim
4 Occurrences trouvées, Dernière modification :
potentiel_energy_surface @teaching:progappchim:matplotlib_gallery
4 Occurrences trouvées, Dernière modification :
exos_empreinte_carbone @teaching
3 Occurrences trouvées, Dernière modification :
lancer_pieces @teaching:exos
3 Occurrences trouvées, Dernière modification :
calcul_matriciel_2012 @teaching:progappchim
3 Occurrences trouvées, Dernière modification :
csv @teaching:progappchim
3 Occurrences trouvées, Dernière modification :
dictionary_adn_protein @teaching:progappchim
3 Occurrences trouvées, Dernière modification :
fizz_buzz @teaching:progappchim
3 Occurrences trouvées, Dernière modification :
polynomes-6 @teaching:progappchim
3 Occurrences trouvées, Dernière modification :
polynomes-10 @teaching:progappchim
3 Occurrences trouvées, Dernière modification :
python @floss
2 Occurrences trouvées, Dernière modification :
informatique @teaching
2 Occurrences trouvées, Dernière modification :
faq @floss:python
2 Occurrences trouvées, Dernière modification :
paradoxe_anniversaires @teaching:exos
2 Occurrences trouvées, Dernière modification :
analyse_images @teaching:progappchim
2 Occurrences trouvées, Dernière modification :
ensemble_mandelbrot_2013 @teaching:progappchim
2 Occurrences trouvées, Dernière modification :
fit_modele_einstein @teaching:progappchim
2 Occurrences trouvées, Dernière modification :
glossaire_chimie @teaching:progappchim
2 Occurrences trouvées, Dernière modification :
ph_acides_bases_2013 @teaching:progappchim
2 Occurrences trouvées, Dernière modification :
polynomes-2 @teaching:progappchim
2 Occurrences trouvées, Dernière modification :
polynomes-3 @teaching:progappchim
2 Occurrences trouvées, Dernière modification :
polynomes-4 @teaching:progappchim
2 Occurrences trouvées, Dernière modification :
polynomes-11 @teaching:progappchim
2 Occurrences trouvées, Dernière modification :
representation_molecules_2013 @teaching:progappchim
2 Occurrences trouvées, Dernière modification :
solubilite_ph_t @teaching:progappchim
2 Occurrences trouvées, Dernière modification :
tris @teaching:progappchim
2 Occurrences trouvées, Dernière modification :
cuisine_moleculaire @teaching
1 Occurrences trouvées, Dernière modification :
exos_energie_d_ionisation @teaching
1 Occurrences trouvées, Dernière modification :
protoxyde_azote @teaching
1 Occurrences trouvées, Dernière modification :
chempy @teaching:progappchim
1 Occurrences trouvées, Dernière modification :
codes_presentation @teaching:progappchim
1 Occurrences trouvées, Dernière modification :
collection_counter_exemple @teaching:progappchim
1 Occurrences trouvées, Dernière modification :
factorielle @teaching:progappchim
1 Occurrences trouvées, Dernière modification :
game_of_life_conway-2012 @teaching:progappchim
1 Occurrences trouvées, Dernière modification :
koch_snowflake @teaching:progappchim
1 Occurrences trouvées, Dernière modification :
osm_interrogation @teaching:progappchim
1 Occurrences trouvées, Dernière modification :
pavage_penrose_2013 @teaching:progappchim
1 Occurrences trouvées, Dernière modification :
polynomes @teaching:progappchim
1 Occurrences trouvées, Dernière modification :
polynomes-5 @teaching:progappchim
1 Occurrences trouvées, Dernière modification :
polynomes-7-contrib1 @teaching:progappchim
1 Occurrences trouvées, Dernière modification :
pressions_partielles_systemes_non_ideaux @teaching:progappchim
1 Occurrences trouvées, Dernière modification :
print_format @teaching:progappchim
1 Occurrences trouvées, Dernière modification :
random_walk_2d-simple @teaching:progappchim
1 Occurrences trouvées, Dernière modification :
tableau_periodique_2013 @teaching:progappchim
1 Occurrences trouvées, Dernière modification :
potentiel_morse @teaching:progappchim:matplotlib_gallery
1 Occurrences trouvées, Dernière modification :