SlideShare uma empresa Scribd logo
1 de 41
Baixar para ler offline
Potter x Voldemort:
Lições Ofidiglotas da Prática
         Pythonica


            Rodrigo Senra - rsenra@acm.org
             PythonBrasil[6] - Curitiba - PR
                                           1
Anatomia do Blá

• Eu, Vocês e Python
• Potter x Voldemort: o porquê !
• Hack Maligno: Depurador Omnisciente
• 1 palavra dos patrocinadores

                                        2
• Engenheiro de Computação
  Graduação-MSc-(PhD quase acabando) IC-Unicamp


• Desenvolvedor e Projetista de Software
  na HI Tecnologia (desde 2008)
  (no mercado desde 1996 )


• Entusiasta deem 1997)
  (primeiro contato
                    Python



                         3
                                                  3
Cenas dos últimos capítulos...

[1] 2005 - BigKahuna
[2] 2006 - Show Pyrotécnico
          Iteradores, Geradores,Hooks,Decoradores
[3] 2007 - Show Pyrotécnico II
          Routing, RTSP, Twisted, GIS
[4] 2008 - ISIS-NBP
         Bibliotecas Digitais
[5] 2009 - Rest, Gtw e Compiladores
        SFC(Rede Petri) + ST(Pascal) > Ladder
                                                    4
Python: 1001 utilidades




                          5
Python: 1001 utilidades
 Interface IPTABLES (Python > Linux Kernel)
                        Alta-disponibilidade para Clusters Linux
Servidor de Streaming (RTSP)

                    Sintetizador de Voz (CPqD’s TextoFala, MRCP)

   Monitoramento Remoto (Zenoss before Zenoss)
                                Gerador de tráfego - TCP/UDP

Automação de Força de Vendas
                          Rastreamento de pornografia em Intranet
 Bibliotecas Digitais
                        Sistemas de Cadastros Governamentais
 Gerenciamento de Riscos (Com JS)

                                                                    5
Python: 1001 utilidades
Interface IPTABLES (Python > Linux Kernel)
Alta-disponibilidade para Clusters Linux
Servidor de Streaming (RTSP)
Sintetizador de Voz (CPqD’s TextoFala, MRCP)
Monitoramento Remoto (Zenoss before Zenoss)
Gerador de tráfego - TCP/UDP
Automação de Força de Vendas
Rastreamento de pornografia em Intranet
Bibliotecas Digitais
Sistemas de Cadastros Governamentais
Gerenciamento de Riscos (Com JS)


                                               6
Quem está aí ?




                 7
Quem está aí ?
✓Profissionais de
  Informática




                          7
Quem está aí ?
✓Profissionais de
  Informática

✓Desenvolvedores




                          7
Quem está aí ?
✓Profissionais de
  Informática

✓Desenvolvedores
✓Estudantes




                          7
Quem está aí ?
✓Profissionais de
  Informática

✓Desenvolvedores
✓Estudantes
✓Professores



                          7
Quem está aí ?
✓Profissionais de
  Informática

✓Desenvolvedores
✓Estudantes
✓Professores
✓1ª vez na PyConBrasil


                          7
Quem está aí ?
✓Profissionais de
  Informática

✓Desenvolvedores
✓Estudantes
✓Professores
✓1ª vez na PyConBrasil
✓Membros APyBr

                          7
Quem está aí ?
✓Profissionais de
    Informática

✓Desenvolvedores
✓Estudantes
✓Professores
✓1ª vez na PyConBrasil
✓Membros APyBr
•   Nenhuma resposta acima!


                              7
O porquê do título !


                       8
Duelo de linguagens




                      9
Duelo de linguagens




                      9
Duelo de linguagens




                      10
11
Java
import java.io.*;
import java.util.*;
import java.text.*;
public class sumcol {
public static void main(String[] args) {
     int count = 0;
     String line;
     try {
        BufferedReader in = new BufferedReader(
                 new InputStreamReader(System.in));
        while ((line = in.readLine()) != null) {
           count = count + Integer.parseInt(line);
        }
     } catch (IOException e) { }
     System.out.println(Integer.toString(count));



                                                      11
Java
                                         C#
importSystem;
using java.io.*;
importApp {
class java.util.*;
import static int Main(String[] args) {
public java.text.*;
public class sumcol {
     int count = 0;
public static void main(String[] args) {
     for (String line = Console.In.ReadLine();
     int count != 0;
           line = null;
     String line; Console.In.ReadLine())
           line =
     try {count += System.Convert.ToInt32(line); }
       {
         BufferedReader in = new BufferedReader(
     Console.WriteLine(count.ToString());
     return(0); new InputStreamReader(System.in));
   }     while ((line = in.readLine()) != null) {
            count = count + Integer.parseInt(line);
         }
     } catch (IOException e) { }
     System.out.println(Integer.toString(count));



                                                      11
Python
                                      Java
                                       C#
importSystem;
import java.io.*;
using sys
importApp {
class java.util.*;
count = 0
import1:
public java.text.*;
while static int Main(String[] args) {
public class sumcol {
   line = count = 0;
       int sys.stdin.readline().strip()
public static void main(String[] args) {
       for (String line = Console.In.ReadLine();
   if not line:
       int count != 0;
       break line = null;
   count += line; Console.In.ReadLine())
       String int(line)
             line =
print try {count += System.Convert.ToInt32(line); }
         {
       count
           BufferedReader in = new BufferedReader(
       Console.WriteLine(count.ToString());
       return(0); new InputStreamReader(System.in));
   }       while ((line = in.readLine()) != null) {
              count = count + Integer.parseInt(line);
           }
       } catch (IOException e) { }
       System.out.println(Integer.toString(count));



                                                        11
Python
                                      Java
                                       C#
importSystem;
import java.io.*;
using sys
importApp { itertools
count java.util.*;
class sys,
import= 0
import1:
public java.text.*;
while static int Main(String[] args) {
print sum(itertools.imap(int, sys.stdin))
public class sumcol {
   line = count = 0;
       int sys.stdin.readline().strip()
public static void main(String[] args) {
       for (String line = Console.In.ReadLine();
   if not line:
       int count != 0;
       break line = null;
   count += line; Console.In.ReadLine())
       String int(line)
             line =
print try {count += System.Convert.ToInt32(line); }
         {
       count
           BufferedReader in = new BufferedReader(
       Console.WriteLine(count.ToString());
       return(0); new InputStreamReader(System.in));
   }       while ((line = in.readLine()) != null) {
              count = count + Integer.parseInt(line);
           }
       } catch (IOException e) { }
       System.out.println(Integer.toString(count));



                                                        11
Truth lies on statistics!



                            12
13
40          50         60        70         80         90        2000

Plankalkü    Fortran    COBOL      Pascal     Ada      Javascript    D
              LISP      SIMULA       C        C++      Python        C#
                         BASIC    Smalltalk   Perl        Java       Go
                         LOGO      Prolog     SQL         PHP

                         ITS       UNIX           LISA     BeOS    Mac OSX
                        OS360      CP/M         Macintosh  Linux    Linux
                       MULTICS     VMS           UNIX     Solaris
                                                MS-DOS OpenBSD Windows
                                                                     ME
                                                Windows Windows
                                                                    2000
                                                 1.0-2.0  2.0 - 98
                                     Ethernet                        XP
                         RS-232                   OS/2              Vista
                                      TCP/IP     MINIX
                       ARPANET PONG                                   7
                                                  AIX
              Circuito Virt.Mem                  HPUX
                                       Micro-
             Integrado Interrupções processador   SCO
                                                  GNU     WWW
Transistor   Harddisk     Mouse       Floppy
                                                  RISC      ISA


                                                                             13
http://www.tiobe.com
                   14
http://www.tiobe.com
                   14
x86 Ubuntu™ Intel® Q6600® one core - http://shootout.alioth.debian.org/ 
                                                                           15
Hack Maligno
Depurador Omnisciente
                        16
Omniscient Debugger
  “... describes the concept that debuggers should
  know everything about the run of a program,
  that they should remember every state change,
  and be able to present to you the value of
  any variable at any point in time.
  Essentially, omniscient debugging means
  that you can go backwards in time.”




                                                       Bil Lewis
In 1969, Bob Balzer implemented a version of
omniscient debugging for Fortran that ran on
                                                       2006-01-11
 a mainframe and had a TTY interface                   http://video.google.com/videoplay?docid=3897010229726822034#
(see “EXDAMS—Extendible Debugging and Monitoring
System,” ACM Spring Joint Computer Conference, 1969)

                                                                                                                      17
18
Quem assistiu (ontem)
     a palestra
MetaPython Reciclado
      do JS ?

 Vamos ter que usar
   aquela fábrica
  de metaclasses ?


                        19
Hora da Demo
 Dá tempo de ver
o Python em ação ?
    É possível ?
Seria pedir muito ?




                      20
Uma palavra dos patrocinadores...




                                    21
Uma palavra dos patrocinadores...




                                    21
Perguntas ?
Comentários ?

                22
Até crianças
podem lidar com Python!



                          23
Até crianças
podem lidar com Python!



                          23
Obrigado a todos
                         pela atenção.

                            Rodrigo Dias Arruda Senra
                                 http://rodrigo.senra.nom.br
                                      rsenra@acm.org


As opiniões e conclusões expressas nesta apresentação são de exclusiva responsabilidade de Rodrigo Senra.

Não é necessário requisitar permissão do autor para o uso de partes ou do todo desta apresentação, desde que
não sejam feitas alterações no conteúdo reutilizado e que esta nota esteja presente na íntegra no material
resultante.

Imagens e referências para outros trabalhos nesta apresentação permanecem propriedade daqueles que detêm
seus direitos de copyright.

                                                                                                               24

Mais conteúdo relacionado

Mais procurados

Øredev 2011 - JVM JIT for Dummies (What the JVM Does With Your Bytecode When ...
Øredev 2011 - JVM JIT for Dummies (What the JVM Does With Your Bytecode When ...Øredev 2011 - JVM JIT for Dummies (What the JVM Does With Your Bytecode When ...
Øredev 2011 - JVM JIT for Dummies (What the JVM Does With Your Bytecode When ...Charles Nutter
 
RISC-V : Berkeley Boot Loader & Proxy Kernelのソースコード解析
RISC-V : Berkeley Boot Loader & Proxy Kernelのソースコード解析RISC-V : Berkeley Boot Loader & Proxy Kernelのソースコード解析
RISC-V : Berkeley Boot Loader & Proxy Kernelのソースコード解析Mr. Vengineer
 
What the &~#@<!? (Pointers in Rust)
What the &~#@<!? (Pointers in Rust)What the &~#@<!? (Pointers in Rust)
What the &~#@<!? (Pointers in Rust)David Evans
 
Segmentation Faults, Page Faults, Processes, Threads, and Tasks
Segmentation Faults, Page Faults, Processes, Threads, and TasksSegmentation Faults, Page Faults, Processes, Threads, and Tasks
Segmentation Faults, Page Faults, Processes, Threads, and TasksDavid Evans
 
Learn Python 3 for absolute beginners
Learn Python 3 for absolute beginnersLearn Python 3 for absolute beginners
Learn Python 3 for absolute beginnersKingsleyAmankwa
 
Exploitation of counter overflows in the Linux kernel
Exploitation of counter overflows in the Linux kernelExploitation of counter overflows in the Linux kernel
Exploitation of counter overflows in the Linux kernelVitaly Nikolenko
 
A Brief History of UniRx/UniTask, IUniTaskSource in Depth
A Brief History of UniRx/UniTask, IUniTaskSource in DepthA Brief History of UniRx/UniTask, IUniTaskSource in Depth
A Brief History of UniRx/UniTask, IUniTaskSource in DepthYoshifumi Kawai
 
Learning Python from Data
Learning Python from DataLearning Python from Data
Learning Python from DataMosky Liu
 
Secure coding for developers
Secure coding for developersSecure coding for developers
Secure coding for developerssluge
 
Advanced cfg bypass on adobe flash player 18 defcon russia 23
Advanced cfg bypass on adobe flash player 18 defcon russia 23Advanced cfg bypass on adobe flash player 18 defcon russia 23
Advanced cfg bypass on adobe flash player 18 defcon russia 23DefconRussia
 
Practicing Python 3
Practicing Python 3Practicing Python 3
Practicing Python 3Mosky Liu
 
sizeof(Object): how much memory objects take on JVMs and when this may matter
sizeof(Object): how much memory objects take on JVMs and when this may mattersizeof(Object): how much memory objects take on JVMs and when this may matter
sizeof(Object): how much memory objects take on JVMs and when this may matterDawid Weiss
 
Gpu workshop cluster universe: scripting cuda
Gpu workshop cluster universe: scripting cudaGpu workshop cluster universe: scripting cuda
Gpu workshop cluster universe: scripting cudaFerdinand Jamitzky
 
System Hacking Tutorial #1 - Introduction to Vulnerability and Type of Vulner...
System Hacking Tutorial #1 - Introduction to Vulnerability and Type of Vulner...System Hacking Tutorial #1 - Introduction to Vulnerability and Type of Vulner...
System Hacking Tutorial #1 - Introduction to Vulnerability and Type of Vulner...sanghwan ahn
 
grsecurity and PaX
grsecurity and PaXgrsecurity and PaX
grsecurity and PaXKernel TLV
 
Kernel-Level Programming: Entering Ring Naught
Kernel-Level Programming: Entering Ring NaughtKernel-Level Programming: Entering Ring Naught
Kernel-Level Programming: Entering Ring NaughtDavid Evans
 
Specializing the Data Path - Hooking into the Linux Network Stack
Specializing the Data Path - Hooking into the Linux Network StackSpecializing the Data Path - Hooking into the Linux Network Stack
Specializing the Data Path - Hooking into the Linux Network StackKernel TLV
 
Boost.Python - domesticating the snake
Boost.Python - domesticating the snakeBoost.Python - domesticating the snake
Boost.Python - domesticating the snakeSławomir Zborowski
 
Parsing JSON Really Quickly: Lessons Learned
Parsing JSON Really Quickly: Lessons LearnedParsing JSON Really Quickly: Lessons Learned
Parsing JSON Really Quickly: Lessons LearnedDaniel Lemire
 

Mais procurados (20)

Øredev 2011 - JVM JIT for Dummies (What the JVM Does With Your Bytecode When ...
Øredev 2011 - JVM JIT for Dummies (What the JVM Does With Your Bytecode When ...Øredev 2011 - JVM JIT for Dummies (What the JVM Does With Your Bytecode When ...
Øredev 2011 - JVM JIT for Dummies (What the JVM Does With Your Bytecode When ...
 
RISC-V : Berkeley Boot Loader & Proxy Kernelのソースコード解析
RISC-V : Berkeley Boot Loader & Proxy Kernelのソースコード解析RISC-V : Berkeley Boot Loader & Proxy Kernelのソースコード解析
RISC-V : Berkeley Boot Loader & Proxy Kernelのソースコード解析
 
What the &~#@<!? (Pointers in Rust)
What the &~#@<!? (Pointers in Rust)What the &~#@<!? (Pointers in Rust)
What the &~#@<!? (Pointers in Rust)
 
Segmentation Faults, Page Faults, Processes, Threads, and Tasks
Segmentation Faults, Page Faults, Processes, Threads, and TasksSegmentation Faults, Page Faults, Processes, Threads, and Tasks
Segmentation Faults, Page Faults, Processes, Threads, and Tasks
 
Down the Rabbit Hole
Down the Rabbit HoleDown the Rabbit Hole
Down the Rabbit Hole
 
Learn Python 3 for absolute beginners
Learn Python 3 for absolute beginnersLearn Python 3 for absolute beginners
Learn Python 3 for absolute beginners
 
Exploitation of counter overflows in the Linux kernel
Exploitation of counter overflows in the Linux kernelExploitation of counter overflows in the Linux kernel
Exploitation of counter overflows in the Linux kernel
 
A Brief History of UniRx/UniTask, IUniTaskSource in Depth
A Brief History of UniRx/UniTask, IUniTaskSource in DepthA Brief History of UniRx/UniTask, IUniTaskSource in Depth
A Brief History of UniRx/UniTask, IUniTaskSource in Depth
 
Learning Python from Data
Learning Python from DataLearning Python from Data
Learning Python from Data
 
Secure coding for developers
Secure coding for developersSecure coding for developers
Secure coding for developers
 
Advanced cfg bypass on adobe flash player 18 defcon russia 23
Advanced cfg bypass on adobe flash player 18 defcon russia 23Advanced cfg bypass on adobe flash player 18 defcon russia 23
Advanced cfg bypass on adobe flash player 18 defcon russia 23
 
Practicing Python 3
Practicing Python 3Practicing Python 3
Practicing Python 3
 
sizeof(Object): how much memory objects take on JVMs and when this may matter
sizeof(Object): how much memory objects take on JVMs and when this may mattersizeof(Object): how much memory objects take on JVMs and when this may matter
sizeof(Object): how much memory objects take on JVMs and when this may matter
 
Gpu workshop cluster universe: scripting cuda
Gpu workshop cluster universe: scripting cudaGpu workshop cluster universe: scripting cuda
Gpu workshop cluster universe: scripting cuda
 
System Hacking Tutorial #1 - Introduction to Vulnerability and Type of Vulner...
System Hacking Tutorial #1 - Introduction to Vulnerability and Type of Vulner...System Hacking Tutorial #1 - Introduction to Vulnerability and Type of Vulner...
System Hacking Tutorial #1 - Introduction to Vulnerability and Type of Vulner...
 
grsecurity and PaX
grsecurity and PaXgrsecurity and PaX
grsecurity and PaX
 
Kernel-Level Programming: Entering Ring Naught
Kernel-Level Programming: Entering Ring NaughtKernel-Level Programming: Entering Ring Naught
Kernel-Level Programming: Entering Ring Naught
 
Specializing the Data Path - Hooking into the Linux Network Stack
Specializing the Data Path - Hooking into the Linux Network StackSpecializing the Data Path - Hooking into the Linux Network Stack
Specializing the Data Path - Hooking into the Linux Network Stack
 
Boost.Python - domesticating the snake
Boost.Python - domesticating the snakeBoost.Python - domesticating the snake
Boost.Python - domesticating the snake
 
Parsing JSON Really Quickly: Lessons Learned
Parsing JSON Really Quickly: Lessons LearnedParsing JSON Really Quickly: Lessons Learned
Parsing JSON Really Quickly: Lessons Learned
 

Destaque

Cases de Python no 7Masters 2012
Cases de Python no 7Masters 2012Cases de Python no 7Masters 2012
Cases de Python no 7Masters 2012Rodrigo Senra
 
Rest, Gateway e Compiladores
Rest, Gateway e CompiladoresRest, Gateway e Compiladores
Rest, Gateway e CompiladoresRodrigo Senra
 
Organicer: Organizando informação com Python
Organicer: Organizando informação com PythonOrganicer: Organizando informação com Python
Organicer: Organizando informação com PythonRodrigo Senra
 
Python: Cabe no seu bolso, no seu micro, no seu cérebro.
Python: Cabe no seu bolso, no seu micro, no seu cérebro.Python: Cabe no seu bolso, no seu micro, no seu cérebro.
Python: Cabe no seu bolso, no seu micro, no seu cérebro.Rodrigo Senra
 
Depurador onisciente
Depurador oniscienteDepurador onisciente
Depurador oniscienteRodrigo Senra
 
Brainiak: Um plano maligno de dominação semântica hipermídia
Brainiak: Um plano maligno de dominação semântica hipermídiaBrainiak: Um plano maligno de dominação semântica hipermídia
Brainiak: Um plano maligno de dominação semântica hipermídiaRodrigo Senra
 
Uma breve história no tempo...da computação
Uma breve história no tempo...da computaçãoUma breve história no tempo...da computação
Uma breve história no tempo...da computaçãoRodrigo Senra
 
Tech talk about iswc2013
Tech talk about iswc2013Tech talk about iswc2013
Tech talk about iswc2013Rodrigo Senra
 
Rupy2014 - Show Pyrotécnico
Rupy2014 - Show PyrotécnicoRupy2014 - Show Pyrotécnico
Rupy2014 - Show PyrotécnicoRodrigo Senra
 
Show Pyrotécnico - Keynote PythonBrasil[9] 2013
Show Pyrotécnico - Keynote PythonBrasil[9] 2013Show Pyrotécnico - Keynote PythonBrasil[9] 2013
Show Pyrotécnico - Keynote PythonBrasil[9] 2013Rodrigo Senra
 
Linked data at globo.com
Linked data at globo.comLinked data at globo.com
Linked data at globo.comRodrigo Senra
 
Rest - Representational State Transfer (EMC BRDC Internal Tech talk)
Rest - Representational State Transfer (EMC BRDC Internal Tech talk)Rest - Representational State Transfer (EMC BRDC Internal Tech talk)
Rest - Representational State Transfer (EMC BRDC Internal Tech talk)Rodrigo Senra
 
Brainiak - uma API REST Hipermedia
Brainiak - uma API REST Hipermedia Brainiak - uma API REST Hipermedia
Brainiak - uma API REST Hipermedia Rodrigo Senra
 
Python: A Arma Secreta do Cientista de Dados
Python: A Arma Secreta do Cientista de DadosPython: A Arma Secreta do Cientista de Dados
Python: A Arma Secreta do Cientista de DadosRodrigo Senra
 
Python: a arma secreta do Cientista de Dados
Python: a arma secreta do Cientista de DadosPython: a arma secreta do Cientista de Dados
Python: a arma secreta do Cientista de DadosRodrigo Senra
 
Cientista de Dados - A profissão mais sexy do século 21
Cientista de Dados - A profissão mais sexy do século 21Cientista de Dados - A profissão mais sexy do século 21
Cientista de Dados - A profissão mais sexy do século 21Rodrigo Senra
 

Destaque (17)

Cases de Python no 7Masters 2012
Cases de Python no 7Masters 2012Cases de Python no 7Masters 2012
Cases de Python no 7Masters 2012
 
Rest, Gateway e Compiladores
Rest, Gateway e CompiladoresRest, Gateway e Compiladores
Rest, Gateway e Compiladores
 
Organicer: Organizando informação com Python
Organicer: Organizando informação com PythonOrganicer: Organizando informação com Python
Organicer: Organizando informação com Python
 
Python: Cabe no seu bolso, no seu micro, no seu cérebro.
Python: Cabe no seu bolso, no seu micro, no seu cérebro.Python: Cabe no seu bolso, no seu micro, no seu cérebro.
Python: Cabe no seu bolso, no seu micro, no seu cérebro.
 
Depurador onisciente
Depurador oniscienteDepurador onisciente
Depurador onisciente
 
Brainiak: Um plano maligno de dominação semântica hipermídia
Brainiak: Um plano maligno de dominação semântica hipermídiaBrainiak: Um plano maligno de dominação semântica hipermídia
Brainiak: Um plano maligno de dominação semântica hipermídia
 
Uma breve história no tempo...da computação
Uma breve história no tempo...da computaçãoUma breve história no tempo...da computação
Uma breve história no tempo...da computação
 
Tech talk about iswc2013
Tech talk about iswc2013Tech talk about iswc2013
Tech talk about iswc2013
 
Rupy2014 - Show Pyrotécnico
Rupy2014 - Show PyrotécnicoRupy2014 - Show Pyrotécnico
Rupy2014 - Show Pyrotécnico
 
Cientista de Dados
Cientista de DadosCientista de Dados
Cientista de Dados
 
Show Pyrotécnico - Keynote PythonBrasil[9] 2013
Show Pyrotécnico - Keynote PythonBrasil[9] 2013Show Pyrotécnico - Keynote PythonBrasil[9] 2013
Show Pyrotécnico - Keynote PythonBrasil[9] 2013
 
Linked data at globo.com
Linked data at globo.comLinked data at globo.com
Linked data at globo.com
 
Rest - Representational State Transfer (EMC BRDC Internal Tech talk)
Rest - Representational State Transfer (EMC BRDC Internal Tech talk)Rest - Representational State Transfer (EMC BRDC Internal Tech talk)
Rest - Representational State Transfer (EMC BRDC Internal Tech talk)
 
Brainiak - uma API REST Hipermedia
Brainiak - uma API REST Hipermedia Brainiak - uma API REST Hipermedia
Brainiak - uma API REST Hipermedia
 
Python: A Arma Secreta do Cientista de Dados
Python: A Arma Secreta do Cientista de DadosPython: A Arma Secreta do Cientista de Dados
Python: A Arma Secreta do Cientista de Dados
 
Python: a arma secreta do Cientista de Dados
Python: a arma secreta do Cientista de DadosPython: a arma secreta do Cientista de Dados
Python: a arma secreta do Cientista de Dados
 
Cientista de Dados - A profissão mais sexy do século 21
Cientista de Dados - A profissão mais sexy do século 21Cientista de Dados - A profissão mais sexy do século 21
Cientista de Dados - A profissão mais sexy do século 21
 

Semelhante a Python Brasil 2010 - Potter vs Voldemort - Lições ofidiglotas da prática Pythonica

Unmanaged Parallelization via P/Invoke
Unmanaged Parallelization via P/InvokeUnmanaged Parallelization via P/Invoke
Unmanaged Parallelization via P/InvokeDmitri Nesteruk
 
python presentation
python presentationpython presentation
python presentationVaibhavMawal
 
Skiron - Experiments in CPU Design in D
Skiron - Experiments in CPU Design in DSkiron - Experiments in CPU Design in D
Skiron - Experiments in CPU Design in DMithun Hunsur
 
Python For Scientists
Python For ScientistsPython For Scientists
Python For Scientistsaeberspaecher
 
PVS-Studio 5.00, a solution for developers of modern resource-intensive appl...
PVS-Studio 5.00, a solution for developers of modern resource-intensive appl...PVS-Studio 5.00, a solution for developers of modern resource-intensive appl...
PVS-Studio 5.00, a solution for developers of modern resource-intensive appl...Andrey Karpov
 
14.jun.2012
14.jun.201214.jun.2012
14.jun.2012Tech_MX
 
Online test program generator for RISC-V processors
Online test program generator for RISC-V processorsOnline test program generator for RISC-V processors
Online test program generator for RISC-V processorsRISC-V International
 
Wprowadzenie do technologii Big Data / Intro to Big Data Ecosystem
Wprowadzenie do technologii Big Data / Intro to Big Data EcosystemWprowadzenie do technologii Big Data / Intro to Big Data Ecosystem
Wprowadzenie do technologii Big Data / Intro to Big Data EcosystemSages
 
Static analysis of C++ source code
Static analysis of C++ source codeStatic analysis of C++ source code
Static analysis of C++ source codePVS-Studio
 
Static analysis of C++ source code
Static analysis of C++ source codeStatic analysis of C++ source code
Static analysis of C++ source codeAndrey Karpov
 
.NET Foundation, Future of .NET and C#
.NET Foundation, Future of .NET and C#.NET Foundation, Future of .NET and C#
.NET Foundation, Future of .NET and C#Bertrand Le Roy
 
Stackless Python In Eve
Stackless Python In EveStackless Python In Eve
Stackless Python In Evel xf
 
Python for Linux System Administration
Python for Linux System AdministrationPython for Linux System Administration
Python for Linux System Administrationvceder
 
Pysense: wireless sensor computing in Python?
Pysense: wireless sensor computing in Python?Pysense: wireless sensor computing in Python?
Pysense: wireless sensor computing in Python?Davide Carboni
 

Semelhante a Python Brasil 2010 - Potter vs Voldemort - Lições ofidiglotas da prática Pythonica (20)

Using Parallel Computing Platform - NHDNUG
Using Parallel Computing Platform - NHDNUGUsing Parallel Computing Platform - NHDNUG
Using Parallel Computing Platform - NHDNUG
 
Unmanaged Parallelization via P/Invoke
Unmanaged Parallelization via P/InvokeUnmanaged Parallelization via P/Invoke
Unmanaged Parallelization via P/Invoke
 
python presentation
python presentationpython presentation
python presentation
 
Skiron - Experiments in CPU Design in D
Skiron - Experiments in CPU Design in DSkiron - Experiments in CPU Design in D
Skiron - Experiments in CPU Design in D
 
Python For Scientists
Python For ScientistsPython For Scientists
Python For Scientists
 
PVS-Studio 5.00, a solution for developers of modern resource-intensive appl...
PVS-Studio 5.00, a solution for developers of modern resource-intensive appl...PVS-Studio 5.00, a solution for developers of modern resource-intensive appl...
PVS-Studio 5.00, a solution for developers of modern resource-intensive appl...
 
A Gomez T Tat Cesga
A Gomez T Tat CesgaA Gomez T Tat Cesga
A Gomez T Tat Cesga
 
What is Python?
What is Python?What is Python?
What is Python?
 
14.jun.2012
14.jun.201214.jun.2012
14.jun.2012
 
Online test program generator for RISC-V processors
Online test program generator for RISC-V processorsOnline test program generator for RISC-V processors
Online test program generator for RISC-V processors
 
Wprowadzenie do technologii Big Data / Intro to Big Data Ecosystem
Wprowadzenie do technologii Big Data / Intro to Big Data EcosystemWprowadzenie do technologii Big Data / Intro to Big Data Ecosystem
Wprowadzenie do technologii Big Data / Intro to Big Data Ecosystem
 
Static analysis of C++ source code
Static analysis of C++ source codeStatic analysis of C++ source code
Static analysis of C++ source code
 
Static analysis of C++ source code
Static analysis of C++ source codeStatic analysis of C++ source code
Static analysis of C++ source code
 
Next .NET and C#
Next .NET and C#Next .NET and C#
Next .NET and C#
 
.NET Foundation, Future of .NET and C#
.NET Foundation, Future of .NET and C#.NET Foundation, Future of .NET and C#
.NET Foundation, Future of .NET and C#
 
Stackless Python In Eve
Stackless Python In EveStackless Python In Eve
Stackless Python In Eve
 
Playing Nice with Others
Playing Nice with OthersPlaying Nice with Others
Playing Nice with Others
 
Flink internals web
Flink internals web Flink internals web
Flink internals web
 
Python for Linux System Administration
Python for Linux System AdministrationPython for Linux System Administration
Python for Linux System Administration
 
Pysense: wireless sensor computing in Python?
Pysense: wireless sensor computing in Python?Pysense: wireless sensor computing in Python?
Pysense: wireless sensor computing in Python?
 

Último

SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphSIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphNeo4j
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking MenDelhi Call girls
 
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersEnhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersThousandEyes
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking MenDelhi Call girls
 
Key Features Of Token Development (1).pptx
Key  Features Of Token  Development (1).pptxKey  Features Of Token  Development (1).pptx
Key Features Of Token Development (1).pptxLBM Solutions
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationSafe Software
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationSafe Software
 
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | DelhiFULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhisoniya singh
 
Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksSoftradix Technologies
 
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitecturePixlogix Infotech
 
Azure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & ApplicationAzure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & ApplicationAndikSusilo4
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdfhans926745
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)Gabriella Davis
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesSinan KOZAK
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slidespraypatel2
 
AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsMemoori
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024Rafal Los
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationMichael W. Hawkins
 

Último (20)

SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphSIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersEnhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
Key Features Of Token Development (1).pptx
Key  Features Of Token  Development (1).pptxKey  Features Of Token  Development (1).pptx
Key Features Of Token Development (1).pptx
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
 
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | DelhiFULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
 
Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other Frameworks
 
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC Architecture
 
Azure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & ApplicationAzure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & Application
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen Frames
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slides
 
AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial Buildings
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 

Python Brasil 2010 - Potter vs Voldemort - Lições ofidiglotas da prática Pythonica

  • 1. Potter x Voldemort: Lições Ofidiglotas da Prática Pythonica Rodrigo Senra - rsenra@acm.org PythonBrasil[6] - Curitiba - PR 1
  • 2. Anatomia do Blá • Eu, Vocês e Python • Potter x Voldemort: o porquê ! • Hack Maligno: Depurador Omnisciente • 1 palavra dos patrocinadores 2
  • 3. • Engenheiro de Computação Graduação-MSc-(PhD quase acabando) IC-Unicamp • Desenvolvedor e Projetista de Software na HI Tecnologia (desde 2008) (no mercado desde 1996 ) • Entusiasta deem 1997) (primeiro contato Python 3 3
  • 4. Cenas dos últimos capítulos... [1] 2005 - BigKahuna [2] 2006 - Show Pyrotécnico Iteradores, Geradores,Hooks,Decoradores [3] 2007 - Show Pyrotécnico II Routing, RTSP, Twisted, GIS [4] 2008 - ISIS-NBP Bibliotecas Digitais [5] 2009 - Rest, Gtw e Compiladores SFC(Rede Petri) + ST(Pascal) > Ladder 4
  • 6. Python: 1001 utilidades Interface IPTABLES (Python > Linux Kernel) Alta-disponibilidade para Clusters Linux Servidor de Streaming (RTSP) Sintetizador de Voz (CPqD’s TextoFala, MRCP) Monitoramento Remoto (Zenoss before Zenoss) Gerador de tráfego - TCP/UDP Automação de Força de Vendas Rastreamento de pornografia em Intranet Bibliotecas Digitais Sistemas de Cadastros Governamentais Gerenciamento de Riscos (Com JS) 5
  • 7. Python: 1001 utilidades Interface IPTABLES (Python > Linux Kernel) Alta-disponibilidade para Clusters Linux Servidor de Streaming (RTSP) Sintetizador de Voz (CPqD’s TextoFala, MRCP) Monitoramento Remoto (Zenoss before Zenoss) Gerador de tráfego - TCP/UDP Automação de Força de Vendas Rastreamento de pornografia em Intranet Bibliotecas Digitais Sistemas de Cadastros Governamentais Gerenciamento de Riscos (Com JS) 6
  • 9. Quem está aí ? ✓Profissionais de Informática 7
  • 10. Quem está aí ? ✓Profissionais de Informática ✓Desenvolvedores 7
  • 11. Quem está aí ? ✓Profissionais de Informática ✓Desenvolvedores ✓Estudantes 7
  • 12. Quem está aí ? ✓Profissionais de Informática ✓Desenvolvedores ✓Estudantes ✓Professores 7
  • 13. Quem está aí ? ✓Profissionais de Informática ✓Desenvolvedores ✓Estudantes ✓Professores ✓1ª vez na PyConBrasil 7
  • 14. Quem está aí ? ✓Profissionais de Informática ✓Desenvolvedores ✓Estudantes ✓Professores ✓1ª vez na PyConBrasil ✓Membros APyBr 7
  • 15. Quem está aí ? ✓Profissionais de Informática ✓Desenvolvedores ✓Estudantes ✓Professores ✓1ª vez na PyConBrasil ✓Membros APyBr • Nenhuma resposta acima! 7
  • 16. O porquê do título ! 8
  • 20. 11
  • 21. Java import java.io.*; import java.util.*; import java.text.*; public class sumcol { public static void main(String[] args) { int count = 0; String line; try { BufferedReader in = new BufferedReader( new InputStreamReader(System.in)); while ((line = in.readLine()) != null) { count = count + Integer.parseInt(line); } } catch (IOException e) { } System.out.println(Integer.toString(count)); 11
  • 22. Java C# importSystem; using java.io.*; importApp { class java.util.*; import static int Main(String[] args) { public java.text.*; public class sumcol { int count = 0; public static void main(String[] args) { for (String line = Console.In.ReadLine(); int count != 0; line = null; String line; Console.In.ReadLine()) line = try {count += System.Convert.ToInt32(line); } { BufferedReader in = new BufferedReader( Console.WriteLine(count.ToString()); return(0); new InputStreamReader(System.in)); } while ((line = in.readLine()) != null) { count = count + Integer.parseInt(line); } } catch (IOException e) { } System.out.println(Integer.toString(count)); 11
  • 23. Python Java C# importSystem; import java.io.*; using sys importApp { class java.util.*; count = 0 import1: public java.text.*; while static int Main(String[] args) { public class sumcol { line = count = 0; int sys.stdin.readline().strip() public static void main(String[] args) { for (String line = Console.In.ReadLine(); if not line: int count != 0; break line = null; count += line; Console.In.ReadLine()) String int(line) line = print try {count += System.Convert.ToInt32(line); } { count BufferedReader in = new BufferedReader( Console.WriteLine(count.ToString()); return(0); new InputStreamReader(System.in)); } while ((line = in.readLine()) != null) { count = count + Integer.parseInt(line); } } catch (IOException e) { } System.out.println(Integer.toString(count)); 11
  • 24. Python Java C# importSystem; import java.io.*; using sys importApp { itertools count java.util.*; class sys, import= 0 import1: public java.text.*; while static int Main(String[] args) { print sum(itertools.imap(int, sys.stdin)) public class sumcol { line = count = 0; int sys.stdin.readline().strip() public static void main(String[] args) { for (String line = Console.In.ReadLine(); if not line: int count != 0; break line = null; count += line; Console.In.ReadLine()) String int(line) line = print try {count += System.Convert.ToInt32(line); } { count BufferedReader in = new BufferedReader( Console.WriteLine(count.ToString()); return(0); new InputStreamReader(System.in)); } while ((line = in.readLine()) != null) { count = count + Integer.parseInt(line); } } catch (IOException e) { } System.out.println(Integer.toString(count)); 11
  • 25. Truth lies on statistics! 12
  • 26. 13
  • 27. 40 50 60 70 80 90 2000 Plankalkü Fortran COBOL Pascal Ada Javascript D LISP SIMULA C C++ Python C# BASIC Smalltalk Perl Java Go LOGO Prolog SQL PHP ITS UNIX LISA BeOS Mac OSX OS360 CP/M Macintosh Linux Linux MULTICS VMS UNIX Solaris MS-DOS OpenBSD Windows ME Windows Windows 2000 1.0-2.0 2.0 - 98 Ethernet XP RS-232 OS/2 Vista TCP/IP MINIX ARPANET PONG 7 AIX Circuito Virt.Mem HPUX Micro- Integrado Interrupções processador SCO GNU WWW Transistor Harddisk Mouse Floppy RISC ISA 13
  • 30. x86 Ubuntu™ Intel® Q6600® one core - http://shootout.alioth.debian.org/  15
  • 32. Omniscient Debugger “... describes the concept that debuggers should know everything about the run of a program, that they should remember every state change, and be able to present to you the value of any variable at any point in time. Essentially, omniscient debugging means that you can go backwards in time.” Bil Lewis In 1969, Bob Balzer implemented a version of omniscient debugging for Fortran that ran on 2006-01-11 a mainframe and had a TTY interface http://video.google.com/videoplay?docid=3897010229726822034# (see “EXDAMS—Extendible Debugging and Monitoring System,” ACM Spring Joint Computer Conference, 1969) 17
  • 33. 18
  • 34. Quem assistiu (ontem) a palestra MetaPython Reciclado do JS ? Vamos ter que usar aquela fábrica de metaclasses ? 19
  • 35. Hora da Demo Dá tempo de ver o Python em ação ? É possível ? Seria pedir muito ? 20
  • 36. Uma palavra dos patrocinadores... 21
  • 37. Uma palavra dos patrocinadores... 21
  • 39. Até crianças podem lidar com Python! 23
  • 40. Até crianças podem lidar com Python! 23
  • 41. Obrigado a todos pela atenção. Rodrigo Dias Arruda Senra http://rodrigo.senra.nom.br rsenra@acm.org As opiniões e conclusões expressas nesta apresentação são de exclusiva responsabilidade de Rodrigo Senra. Não é necessário requisitar permissão do autor para o uso de partes ou do todo desta apresentação, desde que não sejam feitas alterações no conteúdo reutilizado e que esta nota esteja presente na íntegra no material resultante. Imagens e referências para outros trabalhos nesta apresentação permanecem propriedade daqueles que detêm seus direitos de copyright. 24