SlideShare una empresa de Scribd logo
1 de 12
Departamento de Programación
Y Tecnología Educativa                                Subprogramas

  Subprogramas

  Es un conjunto de instrucciones que ejecutan una tarea
  específica.


  Pueden ser de dos tipos:


                               Subprograma Sub


                               Subprograma Function

                                                                    Septiembre 2007
                                                           mrodriguez@unimet.edu.ve
Departamento de Programación
 Y Tecnología Educativa                         Subprogramas
Subprogramas tipo SUB
  Cuando el subprograma es invocado, ejecuta las instrucciones
  y luego el control regresa al módulo que lo invocó.




      Invocación


      Ejecución

Indica que
debe retornar
adonde fue
invocado
                                                                 Septiembre 2007
                                                        mrodriguez@unimet.edu.ve
Departamento de Programación
Y Tecnología Educativa                                           Subprogramas

Subprogramas tipo SUB
    Sintaxis de la declaración:
                   Sub Identificador (argumentos o parámetros)
                               Instrucciones
                   End Sub


    Donde:
    Sub y End Sub son palabras reservadas o keywords.

    Identificador es el nombre asignado al subprograma.

    Argumentos o parámetros permiten pasar información al
    Sub. Son opcionales y por ahora sólo pondremos ( )
                                                                               Septiembre 2007
                                                                      mrodriguez@unimet.edu.ve
Departamento de Programación
Y Tecnología Educativa                        Subprogramas

Subprogramas tipo SUB



    Sintaxis de la invocación:
                   Call identificador

    Donde:
    Call es palabra reservada o keyword.

    Identificador es el nombre asignado al subprograma que
    queremos ejecutar.


                                                              Septiembre 2007
                                                     mrodriguez@unimet.edu.ve
Departamento de Programación
Y Tecnología Educativa                             ¿Recuerdas este diagrama
                                                                 jerárquico?

   Cada subtarea representa un submódulo en nuestro programa. En las
   próximas láminas puedes ver cómo se codificaría cada una. No te
   preocupes si no entiendes algunas instrucciones o si algún SUB está
   vacío, aún no hemos llegado a ese nivel de detalle.


                                              Sección



                               Inicio         Alumno                 Final



                Ini_Aux                 Lee_Nom            Cal_Fin           Esc_Fin



             Lee_Not            Cal_Pro       Actualizar       Esc_Rep         Lee_Nom
                                                                                            Septiembre 2007
                                                                                   mrodriguez@unimet.edu.ve
Departamento de Programación
Y Tecnología Educativa         Módulo Principal




                                                Septiembre 2007
                                       mrodriguez@unimet.edu.ve
Departamento de Programación
Y Tecnología Educativa         Módulo Inicio




                                             Septiembre 2007
                                    mrodriguez@unimet.edu.ve
Departamento de Programación
Y Tecnología Educativa         Módulo Inicio




                                             Septiembre 2007
                                    mrodriguez@unimet.edu.ve
Departamento de Programación
Y Tecnología Educativa         Módulo Alumno




                                              Septiembre 2007
                                     mrodriguez@unimet.edu.ve
Departamento de Programación
Y Tecnología Educativa         Módulo Alumno




                                              Septiembre 2007
                                     mrodriguez@unimet.edu.ve
Departamento de Programación
Y Tecnología Educativa         Módulo Final




                                            Septiembre 2007
                                   mrodriguez@unimet.edu.ve
Departamento de Programación
Y Tecnología Educativa         Módulo Final




                                            Septiembre 2007
                                   mrodriguez@unimet.edu.ve

Más contenido relacionado

Último

Pasos para enviar una tarea en SIANET - sólo estudiantes.pdf
Pasos para enviar una tarea en SIANET - sólo estudiantes.pdfPasos para enviar una tarea en SIANET - sólo estudiantes.pdf
Pasos para enviar una tarea en SIANET - sólo estudiantes.pdf
NELLYKATTY
 

Último (20)

4ª SESION la misión santificadora del Espíritu Santo en la vida de la Iglesi...
4ª SESION  la misión santificadora del Espíritu Santo en la vida de la Iglesi...4ª SESION  la misión santificadora del Espíritu Santo en la vida de la Iglesi...
4ª SESION la misión santificadora del Espíritu Santo en la vida de la Iglesi...
 
Tipologías de vínculos afectivos (grupo)
Tipologías de vínculos afectivos (grupo)Tipologías de vínculos afectivos (grupo)
Tipologías de vínculos afectivos (grupo)
 
Pasos para enviar una tarea en SIANET - sólo estudiantes.pdf
Pasos para enviar una tarea en SIANET - sólo estudiantes.pdfPasos para enviar una tarea en SIANET - sólo estudiantes.pdf
Pasos para enviar una tarea en SIANET - sólo estudiantes.pdf
 
Vínculo afectivo (labor expositivo de grupo )
Vínculo afectivo (labor expositivo de grupo )Vínculo afectivo (labor expositivo de grupo )
Vínculo afectivo (labor expositivo de grupo )
 
Comunidades Virtuales de Aprendizaje Caracteristicas.pptx
Comunidades Virtuales de Aprendizaje Caracteristicas.pptxComunidades Virtuales de Aprendizaje Caracteristicas.pptx
Comunidades Virtuales de Aprendizaje Caracteristicas.pptx
 
Evaluación de los Factores Internos de la Organización
Evaluación de los Factores Internos de la OrganizaciónEvaluación de los Factores Internos de la Organización
Evaluación de los Factores Internos de la Organización
 
a propósito de la globalización y sus efectos
a propósito de la globalización y sus efectosa propósito de la globalización y sus efectos
a propósito de la globalización y sus efectos
 
Lecciones 07 Esc. Sabática. Motivados por la esperanza
Lecciones 07 Esc. Sabática. Motivados por la esperanzaLecciones 07 Esc. Sabática. Motivados por la esperanza
Lecciones 07 Esc. Sabática. Motivados por la esperanza
 
Sesión de clase Motivados por la esperanza.pdf
Sesión de clase Motivados por la esperanza.pdfSesión de clase Motivados por la esperanza.pdf
Sesión de clase Motivados por la esperanza.pdf
 
📝 Semana 09 - Tema 01: Tarea - Redacción del texto argumentativo
📝 Semana 09 - Tema 01: Tarea - Redacción del texto argumentativo📝 Semana 09 - Tema 01: Tarea - Redacción del texto argumentativo
📝 Semana 09 - Tema 01: Tarea - Redacción del texto argumentativo
 
LA PRIMERA GUERRA MUNDIAL PARA NIÑOS.pdf
LA PRIMERA GUERRA  MUNDIAL PARA NIÑOS.pdfLA PRIMERA GUERRA  MUNDIAL PARA NIÑOS.pdf
LA PRIMERA GUERRA MUNDIAL PARA NIÑOS.pdf
 
DESCRIPCIÓN-LOS-DILEMAS-DEL-CONOCIMIENTO.pptx
DESCRIPCIÓN-LOS-DILEMAS-DEL-CONOCIMIENTO.pptxDESCRIPCIÓN-LOS-DILEMAS-DEL-CONOCIMIENTO.pptx
DESCRIPCIÓN-LOS-DILEMAS-DEL-CONOCIMIENTO.pptx
 
IMPLICACIONES BIOÉTICAS ANTE EL TRANSHUMANISMO A PARTIR DEL PENSAMIENTO FILOS...
IMPLICACIONES BIOÉTICAS ANTE EL TRANSHUMANISMO A PARTIR DEL PENSAMIENTO FILOS...IMPLICACIONES BIOÉTICAS ANTE EL TRANSHUMANISMO A PARTIR DEL PENSAMIENTO FILOS...
IMPLICACIONES BIOÉTICAS ANTE EL TRANSHUMANISMO A PARTIR DEL PENSAMIENTO FILOS...
 
La historia de la vida estudiantil a 102 años de la fundación de las Normales...
La historia de la vida estudiantil a 102 años de la fundación de las Normales...La historia de la vida estudiantil a 102 años de la fundación de las Normales...
La historia de la vida estudiantil a 102 años de la fundación de las Normales...
 
Power Point: Luz desde el santuario.pptx
Power Point: Luz desde el santuario.pptxPower Point: Luz desde el santuario.pptx
Power Point: Luz desde el santuario.pptx
 
Luz desde el santuario. Escuela Sabática
Luz desde el santuario. Escuela SabáticaLuz desde el santuario. Escuela Sabática
Luz desde el santuario. Escuela Sabática
 
proyecto semana de los Jardines, actividades a realizar para resaltar esta fecha
proyecto semana de los Jardines, actividades a realizar para resaltar esta fechaproyecto semana de los Jardines, actividades a realizar para resaltar esta fecha
proyecto semana de los Jardines, actividades a realizar para resaltar esta fecha
 
2.15. Calendario Civico Escolar 2024.docx
2.15. Calendario Civico Escolar 2024.docx2.15. Calendario Civico Escolar 2024.docx
2.15. Calendario Civico Escolar 2024.docx
 
Seguridad y virus informáticos 12°B 2024
Seguridad y virus informáticos 12°B 2024Seguridad y virus informáticos 12°B 2024
Seguridad y virus informáticos 12°B 2024
 
PATRONES DE REFERENCIA, CRITERIOS Y DIAGNOSTICO Angeles.pptx
PATRONES DE REFERENCIA, CRITERIOS Y DIAGNOSTICO Angeles.pptxPATRONES DE REFERENCIA, CRITERIOS Y DIAGNOSTICO Angeles.pptx
PATRONES DE REFERENCIA, CRITERIOS Y DIAGNOSTICO Angeles.pptx
 

Destacado

How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
ThinkNow
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
Kurio // The Social Media Age(ncy)
 

Destacado (20)

2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot
 
Everything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPTEverything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPT
 
Product Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage EngineeringsProduct Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage Engineerings
 
How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
 
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfAI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
 
Skeleton Culture Code
Skeleton Culture CodeSkeleton Culture Code
Skeleton Culture Code
 
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024
 
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
 
How to have difficult conversations
How to have difficult conversations How to have difficult conversations
How to have difficult conversations
 
Introduction to Data Science
Introduction to Data ScienceIntroduction to Data Science
Introduction to Data Science
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best Practices
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project management
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
 

Subprogramas

  • 1. Departamento de Programación Y Tecnología Educativa Subprogramas Subprogramas Es un conjunto de instrucciones que ejecutan una tarea específica. Pueden ser de dos tipos: Subprograma Sub Subprograma Function Septiembre 2007 mrodriguez@unimet.edu.ve
  • 2. Departamento de Programación Y Tecnología Educativa Subprogramas Subprogramas tipo SUB Cuando el subprograma es invocado, ejecuta las instrucciones y luego el control regresa al módulo que lo invocó. Invocación Ejecución Indica que debe retornar adonde fue invocado Septiembre 2007 mrodriguez@unimet.edu.ve
  • 3. Departamento de Programación Y Tecnología Educativa Subprogramas Subprogramas tipo SUB Sintaxis de la declaración: Sub Identificador (argumentos o parámetros) Instrucciones End Sub Donde: Sub y End Sub son palabras reservadas o keywords. Identificador es el nombre asignado al subprograma. Argumentos o parámetros permiten pasar información al Sub. Son opcionales y por ahora sólo pondremos ( ) Septiembre 2007 mrodriguez@unimet.edu.ve
  • 4. Departamento de Programación Y Tecnología Educativa Subprogramas Subprogramas tipo SUB Sintaxis de la invocación: Call identificador Donde: Call es palabra reservada o keyword. Identificador es el nombre asignado al subprograma que queremos ejecutar. Septiembre 2007 mrodriguez@unimet.edu.ve
  • 5. Departamento de Programación Y Tecnología Educativa ¿Recuerdas este diagrama jerárquico? Cada subtarea representa un submódulo en nuestro programa. En las próximas láminas puedes ver cómo se codificaría cada una. No te preocupes si no entiendes algunas instrucciones o si algún SUB está vacío, aún no hemos llegado a ese nivel de detalle. Sección Inicio Alumno Final Ini_Aux Lee_Nom Cal_Fin Esc_Fin Lee_Not Cal_Pro Actualizar Esc_Rep Lee_Nom Septiembre 2007 mrodriguez@unimet.edu.ve
  • 6. Departamento de Programación Y Tecnología Educativa Módulo Principal Septiembre 2007 mrodriguez@unimet.edu.ve
  • 7. Departamento de Programación Y Tecnología Educativa Módulo Inicio Septiembre 2007 mrodriguez@unimet.edu.ve
  • 8. Departamento de Programación Y Tecnología Educativa Módulo Inicio Septiembre 2007 mrodriguez@unimet.edu.ve
  • 9. Departamento de Programación Y Tecnología Educativa Módulo Alumno Septiembre 2007 mrodriguez@unimet.edu.ve
  • 10. Departamento de Programación Y Tecnología Educativa Módulo Alumno Septiembre 2007 mrodriguez@unimet.edu.ve
  • 11. Departamento de Programación Y Tecnología Educativa Módulo Final Septiembre 2007 mrodriguez@unimet.edu.ve
  • 12. Departamento de Programación Y Tecnología Educativa Módulo Final Septiembre 2007 mrodriguez@unimet.edu.ve