Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
python-kszkepzes
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
bodzsoaa
python-kszkepzes
Commits
ee2cc61a
Commit
ee2cc61a
authored
Mar 27, 2019
by
Bodor Máté
Browse files
Options
Downloads
Patches
Plain Diff
v0.17
parent
fc53258a
No related branches found
No related tags found
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
PITCHME.md
+83
-44
83 additions, 44 deletions
PITCHME.md
with
83 additions
and
44 deletions
PITCHME.md
+
83
−
44
View file @
ee2cc61a
...
@@ -65,7 +65,7 @@ Note:
...
@@ -65,7 +65,7 @@ Note:
---
---
### Miért szeretjük a python?
### Miért szeretjük a python
t
?
Note:
Note:
...
@@ -83,6 +83,7 @@ Note:
...
@@ -83,6 +83,7 @@ Note:
### Tökéletes?!
### Tökéletes?!
+++
+++
### Tökéletes?!
### Tökéletes?!
NEM!
NEM!
...
@@ -90,18 +91,20 @@ NEM!
...
@@ -90,18 +91,20 @@ NEM!
+++
+++
### Tökéletes?!
### Tökéletes?!
-
Lassú, nagyon lassú
-
Zabálja a ramot
-
Viszonylag lassú
-
Nagy memóriaigény
Note:
Note:
+++
+++
Kép: https://benchmarksgame-team.pages.debian.net/benchmarksgame/faster/gpp-python3.html
Kép: https://benchmarksgame-team.pages.debian.net/benchmarksgame/faster/gpp-python3.html
Note:
Note:
https://en.wikipedia.org/wiki/N-body_simulation
https://en.wikipedia.org/wiki/N-body_simulation
---
---
### Csomagok
### Csomagok
-
Webfejlesztés:
-
Webfejlesztés:
...
@@ -136,21 +139,20 @@ Note:
...
@@ -136,21 +139,20 @@ Note:
-
Flexx
-
Flexx
+++
+++
-
Data visualization
-
Data visualization
-
matplotlib
-
matplotlib
-
Plotly
-
Plotly
-
geoplotlib
-
geoplotlib
Note:
Note:
---
---
### Pip
### Pip
-
c
somagkezelő
-
C
somagkezelő
-
e
gy helyen van minden
-
E
gy helyen van minden
-
k
önnyen használható
-
K
önnyen használható
Note:
Note:
...
@@ -163,12 +165,11 @@ Note:
...
@@ -163,12 +165,11 @@ Note:
pip
install
flake8
pip
install
flake8
```
```
---
---
### Virtualenv
### Virtualenv
-
s
aját környezet minden projekthez
-
S
aját környezet minden projekthez
Note:
Note:
...
@@ -195,22 +196,22 @@ python3 -m venv venv
...
@@ -195,22 +196,22 @@ python3 -m venv venv
```
```
```
bash
```
bash
source venv
\
bin
\
activate
source
venv
/
bin
/
activate
```
```
---
---
### Flake8
### Flake8
-
l
inter
-
L
inter
-
s
egít jobb kódot írni:
-
S
egít jobb kódot írni:
-
s
yntax error
-
S
yntax error
-
t
ypo
-
T
ypo
-
r
ossz formázás
-
R
ossz formázás
-
pep8
-
pep8
(Style Guide)
Note:
Note:
pep8:
-
Style Guide
-
Style Guide
-
átlátható
-
átlátható
-
egységes
-
egységes
...
@@ -322,26 +323,34 @@ stringabc
...
@@ -322,26 +323,34 @@ stringabc
+++
+++
-
b
ármilyen típus tartalmazhat (általában egyforma)
-
B
ármilyen típus
t
tartalmazhat (általában egyforma)
-
Az elemek indexelhetőek
-
Az elemek indexelhetőek
-
módosítható(mutable)
-
Módosítható(mutable)
```
python
myList
=
[
'
physics
'
,
'
chemistry
'
,
'
physics
'
,
1997
,
2000
]
```
+++
+++
```
python
```
python
print
(
"
myList[0]:
"
,
myList
[
0
])
list
=
[
'
a
'
,
'
b
'
,
'
c
'
,
1
,
2
,
3
]
print
(
"
myList[1:5]:
"
,
myList
[
1
:
5
])
for
a
in
list
:
print
(
a
)
list
[
4
]
=
22
list
.
append
(
50
)
del
(
list
[
3
])
print
(
list
[
2
:])
```
```
Output:
```
python
```
python
myList
.
append
(
5
)
a
del
myList
[
2
]
b
c
1
2
3
[
'
c
'
,
22
,
3
,
50
]
```
```
---
---
...
@@ -354,15 +363,32 @@ del myList[2]
...
@@ -354,15 +363,32 @@ del myList[2]
-
De nem módosítható(immutable)
-
De nem módosítható(immutable)
+++
```
python
```
python
tup1
=
(
12
,
34.56
)
tuple
=
(
'
a
'
,
'
b
'
,
3
)
tup2
=
(
'
abc
'
,
'
xyz
'
)
item
=
tuple
[
2
]
for
a
in
tuple
:
print
(
a
)
a
,
b
,
c
=
tuple
print
(
c
)
tuple2
=
(
34
,
56
,
'
d
'
)
tuple3
=
tuple
+
tuple2
print
(
tuple3
)
```
```
Output:
```
python
```
python
# tup1[0] = 100;
a
tup3
=
tup1
+
tup2
b
print
(
tup3
)
3
3
(
'
a
'
,
'
b
'
,
3
,
34
,
56
,
'
d
'
)
```
```
---
---
...
@@ -374,14 +400,25 @@ print (tup3)
...
@@ -374,14 +400,25 @@ print (tup3)
-
Kulcs érték pár
-
Kulcs érték pár
-
A kulcs egyedi, érték bármi lehet
-
A kulcs egyedi, érték bármi lehet
```
python
+++
dict
=
{
'
Name
'
:
'
Zara
'
,
'
Age
'
:
,
'
Class
'
:
'
First
'
}
```
```
python
```
python
print
(
"
dict[
'
Name
'
]:
"
,
dict
[
'
Name
'
])
dict
=
{
'
Name
'
:
'
Zara
'
,
'
Age
'
:
10
,
'
Class
'
:
'
First
'
}
dict
[
'
Age
'
]
=
8
dict
[
'
Age
'
]
=
8
for
key
,
value
in
dict
.
items
():
print
(
key
,
"
:
"
,
value
)
del
dict
[
'
Name
'
]
del
dict
[
'
Name
'
]
print
(
'
Name
'
in
dict
)
```
Output:
```
python
Name
:
Zara
Age
:
8
Class
:
First
False
```
```
---
---
...
@@ -393,6 +430,8 @@ del dict['Name']
...
@@ -393,6 +430,8 @@ del dict['Name']
-
mint a lista, csak minden érték egyszer szerepelhet
-
mint a lista, csak minden érték egyszer szerepelhet
-
nem biztos, hogy sorban tárolja
-
nem biztos, hogy sorban tárolja
+++
```
python
```
python
set
=
{
1
,
3
,
5
}
set
=
{
1
,
3
,
5
}
print
(
1
in
set
)
print
(
1
in
set
)
...
@@ -445,7 +484,7 @@ def fibonacci(n = 10):
...
@@ -445,7 +484,7 @@ def fibonacci(n = 10):
-
Tetszőlegesen sok paraméter
-
Tetszőlegesen sok paraméter
```
python
```
python
def
minimum
(
first
,
*
args
):
# *args néven szokás
def
minimum
(
first
,
*
args
):
acc
=
first
acc
=
first
for
x
in
args
:
for
x
in
args
:
if
x
<
acc
:
if
x
<
acc
:
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment