This document provides an example Perl script called count_logins.pl that counts the number of logins for each user on a system by using the 'who' command. The summary explains:
1) The script uses the 'who' command to get user login details and counts the number of logins for each user, storing it in a hash.
2) A getusers subroutine is called that opens a pipe to the 'who' command, loops through the output to count logins for each user, and returns the results in a hash.
3) The script then prints out each user and their number of logins by iterating through the returned hash.
This document discusses Perl packages and namespaces. It explains that packages are used to specify namespaces and avoid name collisions. Namespaces isolate variables and functions into separate "compartments". The document then discusses how to create packages using the 'package' function and how package scope works. It also covers using the 'our' keyword to declare variables within a specific package and avoid warnings. The benefits of modularizing code using packages placed in separate files (modules) is discussed. The document provides an example of a simple Toaster module and how to load it into a Perl program. It concludes by covering different ways to add directories to Perl's @INC array to load additional modules, such as using the '-I' command line option, modifying
This document provides an overview of PHP and MySQL. It defines PHP as a server-side scripting language that is commonly used with MySQL, an open-source database management system. The document discusses key PHP concepts like PHP files, variables, operators, conditional statements, arrays, loops, and functions. It also covers form handling in HTML and PHP. The intended audience is users looking to learn the basics of PHP and how it integrates with MySQL for database management.
This document contains a practice exam with 18 multiple choice questions about PHP functions and concepts. It is registered to Núria Torrescasana of Manresa, Barcelona, Spain. The questions cover topics like PHP functions, arrays, classes, sessions, strings, dates/time, and file handling. The answers to the questions are provided at the end.
PHP and MySQL are open-source technologies commonly used together for building dynamic web applications. PHP is a server-side scripting language designed to integrate with MySQL databases. Key features include using PHP scripts embedded in HTML, variables to store and manipulate data, functions to reuse code, and MySQL functions to connect to databases and execute queries.
The document discusses hashes in Perl programming. It explains that hashes allow the storage of key-value pairs and do not maintain order. It provides examples of creating a hash, accessing values using keys, and iterating through keys and values. It also discusses using hashes to store the genetic code and amino acid translations.
This chapter discusses working with text and numbers in PHP. It covers defining and manipulating strings, including validating, formatting, and changing case. Functions for selecting, replacing, and exploding parts of strings are described. Working with numbers, math operators, variables, and number formatting functions are also summarized. Key string functions include substr(), str_replace(), printf(), and number functions include rand(), round(), pow(), and abs().
PHP functions allow programmers to divide code into reusable pieces. There are three main types of functions: simple functions that don't take arguments, functions with parameters that allow passing data into the function, and functions with return values that return data out of the function. Functions make code more organized and reusable.
This document discusses Perl packages and namespaces. It explains that packages are used to specify namespaces and avoid name collisions. Namespaces isolate variables and functions into separate "compartments". The document then discusses how to create packages using the 'package' function and how package scope works. It also covers using the 'our' keyword to declare variables within a specific package and avoid warnings. The benefits of modularizing code using packages placed in separate files (modules) is discussed. The document provides an example of a simple Toaster module and how to load it into a Perl program. It concludes by covering different ways to add directories to Perl's @INC array to load additional modules, such as using the '-I' command line option, modifying
This document provides an overview of PHP and MySQL. It defines PHP as a server-side scripting language that is commonly used with MySQL, an open-source database management system. The document discusses key PHP concepts like PHP files, variables, operators, conditional statements, arrays, loops, and functions. It also covers form handling in HTML and PHP. The intended audience is users looking to learn the basics of PHP and how it integrates with MySQL for database management.
This document contains a practice exam with 18 multiple choice questions about PHP functions and concepts. It is registered to Núria Torrescasana of Manresa, Barcelona, Spain. The questions cover topics like PHP functions, arrays, classes, sessions, strings, dates/time, and file handling. The answers to the questions are provided at the end.
PHP and MySQL are open-source technologies commonly used together for building dynamic web applications. PHP is a server-side scripting language designed to integrate with MySQL databases. Key features include using PHP scripts embedded in HTML, variables to store and manipulate data, functions to reuse code, and MySQL functions to connect to databases and execute queries.
The document discusses hashes in Perl programming. It explains that hashes allow the storage of key-value pairs and do not maintain order. It provides examples of creating a hash, accessing values using keys, and iterating through keys and values. It also discusses using hashes to store the genetic code and amino acid translations.
This chapter discusses working with text and numbers in PHP. It covers defining and manipulating strings, including validating, formatting, and changing case. Functions for selecting, replacing, and exploding parts of strings are described. Working with numbers, math operators, variables, and number formatting functions are also summarized. Key string functions include substr(), str_replace(), printf(), and number functions include rand(), round(), pow(), and abs().
PHP functions allow programmers to divide code into reusable pieces. There are three main types of functions: simple functions that don't take arguments, functions with parameters that allow passing data into the function, and functions with return values that return data out of the function. Functions make code more organized and reusable.
This document contains sample questions for the Zend Certification PHP 5 exam. It includes multiple choice questions testing PHP 5 language features and best practices related to topics like XML processing, database access, regular expressions, and security. The questions cover syntax, functions, patterns and other PHP concepts that could appear on the certification exam.
This document discusses namespaces, global variables, and docstrings in Python. It explains that namespaces are like dictionaries that keep track of variable names and values. There are local, global, and built-in namespaces. Variables defined outside functions are global and can be accessed from anywhere, but reassigned locally without changing the global value unless declared global. Docstrings provide documentation for modules, functions, classes and are accessed with object.__doc__.
PHP Basic and Fundamental Questions and Answers with Detail ExplanationAbdul Rahman Sherzad
These PHP basic and fundamental questions and answers with detail explanation help students and learners to think comprehensive, and to seek more to understand the concept and the root of each topic concretely.
Incredible Machine with Pipelines and Generatorsdantleech
The document discusses using generators and pipelines in PHP to build a performance testing tool called J-Meter. It begins by explaining generators in PHP and how they allow yielding control and passing values between functions. This enables building asynchronous pipelines where stages can be generators. Various PHP frameworks and patterns for asynchronous programming with generators are mentioned. The document concludes by outlining how generators and pipelines could be used to build the major components of a J-Meter-like performance testing tool in PHP.
This document provides an introduction and tutorial to using PowerShell. It begins by discussing PowerShell's purpose as a scripting language for "gluing" existing components together rather than for low-level programming. The tutorial then demonstrates basic PowerShell concepts like variables, arrays, input/output, conditions, iteration, and functions. It also introduces regular expressions and their special characters. The document is intended to get readers started with PowerShell's basic programming constructs.
PHP is a server-side scripting language used to create dynamic web pages. It allows embedding PHP code within HTML pages and interacting with databases. Key elements of PHP include variables, control structures, functions, and sessions. Sessions store user data on the server instead of the client to avoid cookies and allow tracking users across multiple pages.
This document provides an introduction and overview of PHP, including what PHP is, what is needed to use it, basic syntax, variables, data types, operators, control structures like if/else and loops, functions, and includes/requires. Key points covered include PHP being a server-side scripting language, basic syntax using <?php ?> tags, common variable types and scoping, operators for arithmetic, comparison and logic, and common control structures for conditional execution and repetition.
This document provides information about PHP (Hypertext Preprocessor), including its history, uses, syntax, variables, data types, operators, conditional statements, arrays, loops, functions, and more. Some key points:
- PHP is a widely-used scripting language for building dynamic web pages and applications. It was created in 1995 and runs on web servers.
- PHP code is embedded into HTML files and interpreted by the server before the page is sent to the browser. It allows for the creation of dynamic content.
- PHP is free, runs on most servers, and provides tools for database connectivity, security, and dynamic web page creation. It has advantages over competitors like ASP.
This document discusses operators, expressions, and control statements in PHP. It covers arithmetic, logical, relational, bitwise, and assignment operators. It describes expressions and how they are evaluated in PHP. It also explains control structures like if/elseif/else statements, switch statements, while loops, do-while loops, and how to use break and continue statements. Examples are provided for each concept.
PHP is a server-side scripting language commonly used for web development. It allows creation of dynamic content and applications. Some key things PHP can do include building shopping carts, content management systems, forums, and other web applications. PHP code is processed on the server and the results are sent to the user's browser. Variables, arrays, and other data types can store and manipulate information. Control structures like if/else statements and loops allow conditional execution of code. Functions allow reusable blocks of code to be defined. Sessions allow storing of data across multiple pages for a user.
PHP string function helps us to manipulate string in various ways. There are various types of string function available. Here we discuss some important functions and its use with examples.
The document describes how to create a debugger framework over TCP/IP and HTTP. It discusses launching a debugger, handling debug events on the client and server sides, and processing debug events using a language interpreter. The debugger architecture involves a debug launcher, debug view, debug event listener, and debug event processor. The debug launcher starts the debugger and establishes communication with the remote debug target. The debug view handles UI elements like stack frames. The listener handles events like breakpoints, and the processor uses the language interpreter and AST utilities to generate debug responses.
The document discusses design patterns in PHP5. It provides an overview of different creational, structural and behavioral patterns like factory method, singleton, decorator, proxy, observer and examples of how to implement them in PHP5 using its new object-oriented features like visibility, static properties/methods, interfaces, abstract classes, magic methods and exceptions.
PHP is a scripting language commonly used for web development. It allows dynamic generation of web page content through embedded PHP code. Some key things PHP can do include interacting with databases, processing user input, file handling, and more. PHP code is embedded within HTML using <?php ?> tags and variables, control structures, and other programming elements allow writing logic and dynamic functionality.
This document provides an overview of pre-processor hypertext and core PHP concepts. It discusses software engineering, web programming, and introduces PHP as a scripting language. It covers PHP variables, expressions, operators, conditional statements, functions, arrays, syntax, strings, databases, sessions, cookies, files, email handling, JavaScript, AJAX and XML. It also discusses programming fundamentals like data types, keywords, operators, variables, conditional statements, loops, functions and object-oriented programming concepts.
The document provides an overview of PHP (Hypertext Preprocessor), which is a widely used open-source scripting language used for web development. PHP code is executed on the server and generates HTML that is sent to the browser. PHP can connect to databases, collect form data, send/receive cookies, and more. It runs on many platforms and servers and is easy to learn. The document also covers basic PHP syntax, comments, variables, variable scope, and how to use global and static variables.
The document provides an introduction to PHP, including:
- PHP is a scripting language originally designed for web pages and runs on most operating systems.
- PHP syntax is quite easy if familiar with C-type languages, and it is designed to output to browsers but can also create CLI apps.
- Variables, constants, naming conventions, data types, and basic control structures like if/else, while loops and foreach loops are discussed.
- Combining PHP with XHTML is covered, recommending using functions and an object-oriented approach.
- User input via forms is mentioned, linking to a resource on processing forms with PHP.
The document discusses PHP and MySQL for building web applications. It begins with an introduction to PHP, explaining that PHP is a widely used server-side scripting language suited for web development. It then covers PHP fundamentals like syntax, variables, data types, operators, and control structures. The document also discusses how to connect to and query MySQL databases from PHP. It provides an example of building a simple user registration and login application with PHP and MySQL to store and retrieve user data from a database table.
The document provides an overview of PHP and MySQL. It defines PHP and MySQL, describes a three-tier architecture using XAMPP, and covers various PHP and MySQL concepts like variables, sessions, queries, validation, exporting/importing data, and PDF generation. Key topics covered include the basic syntax of PHP codes, MySQL functions for connection and queries, and using the FPDF library to generate PDFs with PHP.
The document provides an introduction to PHP and MySQL. It defines PHP as a server-side scripting language used to generate dynamic web pages. It describes some key PHP concepts like variables, data types, functions, and control structures. It also covers how to connect to and query MySQL databases from PHP scripts. The goal is to provide basic PHP knowledge and code examples to get started with building PHP/MySQL web applications.
Este documento resume los pasos para realizar pruebas de normalidad en dos variables, el peso y las horas de práctica deportiva, y determinar si estas variables están relacionadas mediante una prueba t de Student. Primero se aplican pruebas de normalidad a cada variable y luego una prueba t de Student para comparar medias y verificar si existe una relación entre el peso y las horas de práctica deportiva.
This document discusses three theories of practice that can create change: cognitive change through insight and reframing, emotional change through control and literacy, and behavioral change through modeling and learning by doing. It also lists characteristics of effective change leaders such as vision, risk-taking, learning from others, and creativity. The document emphasizes that change leaders should use active listening to understand different perspectives and influence change by engaging people in the process from the outset and implementing the change. References are provided to further resources on organizational change and leadership techniques.
This document contains sample questions for the Zend Certification PHP 5 exam. It includes multiple choice questions testing PHP 5 language features and best practices related to topics like XML processing, database access, regular expressions, and security. The questions cover syntax, functions, patterns and other PHP concepts that could appear on the certification exam.
This document discusses namespaces, global variables, and docstrings in Python. It explains that namespaces are like dictionaries that keep track of variable names and values. There are local, global, and built-in namespaces. Variables defined outside functions are global and can be accessed from anywhere, but reassigned locally without changing the global value unless declared global. Docstrings provide documentation for modules, functions, classes and are accessed with object.__doc__.
PHP Basic and Fundamental Questions and Answers with Detail ExplanationAbdul Rahman Sherzad
These PHP basic and fundamental questions and answers with detail explanation help students and learners to think comprehensive, and to seek more to understand the concept and the root of each topic concretely.
Incredible Machine with Pipelines and Generatorsdantleech
The document discusses using generators and pipelines in PHP to build a performance testing tool called J-Meter. It begins by explaining generators in PHP and how they allow yielding control and passing values between functions. This enables building asynchronous pipelines where stages can be generators. Various PHP frameworks and patterns for asynchronous programming with generators are mentioned. The document concludes by outlining how generators and pipelines could be used to build the major components of a J-Meter-like performance testing tool in PHP.
This document provides an introduction and tutorial to using PowerShell. It begins by discussing PowerShell's purpose as a scripting language for "gluing" existing components together rather than for low-level programming. The tutorial then demonstrates basic PowerShell concepts like variables, arrays, input/output, conditions, iteration, and functions. It also introduces regular expressions and their special characters. The document is intended to get readers started with PowerShell's basic programming constructs.
PHP is a server-side scripting language used to create dynamic web pages. It allows embedding PHP code within HTML pages and interacting with databases. Key elements of PHP include variables, control structures, functions, and sessions. Sessions store user data on the server instead of the client to avoid cookies and allow tracking users across multiple pages.
This document provides an introduction and overview of PHP, including what PHP is, what is needed to use it, basic syntax, variables, data types, operators, control structures like if/else and loops, functions, and includes/requires. Key points covered include PHP being a server-side scripting language, basic syntax using <?php ?> tags, common variable types and scoping, operators for arithmetic, comparison and logic, and common control structures for conditional execution and repetition.
This document provides information about PHP (Hypertext Preprocessor), including its history, uses, syntax, variables, data types, operators, conditional statements, arrays, loops, functions, and more. Some key points:
- PHP is a widely-used scripting language for building dynamic web pages and applications. It was created in 1995 and runs on web servers.
- PHP code is embedded into HTML files and interpreted by the server before the page is sent to the browser. It allows for the creation of dynamic content.
- PHP is free, runs on most servers, and provides tools for database connectivity, security, and dynamic web page creation. It has advantages over competitors like ASP.
This document discusses operators, expressions, and control statements in PHP. It covers arithmetic, logical, relational, bitwise, and assignment operators. It describes expressions and how they are evaluated in PHP. It also explains control structures like if/elseif/else statements, switch statements, while loops, do-while loops, and how to use break and continue statements. Examples are provided for each concept.
PHP is a server-side scripting language commonly used for web development. It allows creation of dynamic content and applications. Some key things PHP can do include building shopping carts, content management systems, forums, and other web applications. PHP code is processed on the server and the results are sent to the user's browser. Variables, arrays, and other data types can store and manipulate information. Control structures like if/else statements and loops allow conditional execution of code. Functions allow reusable blocks of code to be defined. Sessions allow storing of data across multiple pages for a user.
PHP string function helps us to manipulate string in various ways. There are various types of string function available. Here we discuss some important functions and its use with examples.
The document describes how to create a debugger framework over TCP/IP and HTTP. It discusses launching a debugger, handling debug events on the client and server sides, and processing debug events using a language interpreter. The debugger architecture involves a debug launcher, debug view, debug event listener, and debug event processor. The debug launcher starts the debugger and establishes communication with the remote debug target. The debug view handles UI elements like stack frames. The listener handles events like breakpoints, and the processor uses the language interpreter and AST utilities to generate debug responses.
The document discusses design patterns in PHP5. It provides an overview of different creational, structural and behavioral patterns like factory method, singleton, decorator, proxy, observer and examples of how to implement them in PHP5 using its new object-oriented features like visibility, static properties/methods, interfaces, abstract classes, magic methods and exceptions.
PHP is a scripting language commonly used for web development. It allows dynamic generation of web page content through embedded PHP code. Some key things PHP can do include interacting with databases, processing user input, file handling, and more. PHP code is embedded within HTML using <?php ?> tags and variables, control structures, and other programming elements allow writing logic and dynamic functionality.
This document provides an overview of pre-processor hypertext and core PHP concepts. It discusses software engineering, web programming, and introduces PHP as a scripting language. It covers PHP variables, expressions, operators, conditional statements, functions, arrays, syntax, strings, databases, sessions, cookies, files, email handling, JavaScript, AJAX and XML. It also discusses programming fundamentals like data types, keywords, operators, variables, conditional statements, loops, functions and object-oriented programming concepts.
The document provides an overview of PHP (Hypertext Preprocessor), which is a widely used open-source scripting language used for web development. PHP code is executed on the server and generates HTML that is sent to the browser. PHP can connect to databases, collect form data, send/receive cookies, and more. It runs on many platforms and servers and is easy to learn. The document also covers basic PHP syntax, comments, variables, variable scope, and how to use global and static variables.
The document provides an introduction to PHP, including:
- PHP is a scripting language originally designed for web pages and runs on most operating systems.
- PHP syntax is quite easy if familiar with C-type languages, and it is designed to output to browsers but can also create CLI apps.
- Variables, constants, naming conventions, data types, and basic control structures like if/else, while loops and foreach loops are discussed.
- Combining PHP with XHTML is covered, recommending using functions and an object-oriented approach.
- User input via forms is mentioned, linking to a resource on processing forms with PHP.
The document discusses PHP and MySQL for building web applications. It begins with an introduction to PHP, explaining that PHP is a widely used server-side scripting language suited for web development. It then covers PHP fundamentals like syntax, variables, data types, operators, and control structures. The document also discusses how to connect to and query MySQL databases from PHP. It provides an example of building a simple user registration and login application with PHP and MySQL to store and retrieve user data from a database table.
The document provides an overview of PHP and MySQL. It defines PHP and MySQL, describes a three-tier architecture using XAMPP, and covers various PHP and MySQL concepts like variables, sessions, queries, validation, exporting/importing data, and PDF generation. Key topics covered include the basic syntax of PHP codes, MySQL functions for connection and queries, and using the FPDF library to generate PDFs with PHP.
The document provides an introduction to PHP and MySQL. It defines PHP as a server-side scripting language used to generate dynamic web pages. It describes some key PHP concepts like variables, data types, functions, and control structures. It also covers how to connect to and query MySQL databases from PHP scripts. The goal is to provide basic PHP knowledge and code examples to get started with building PHP/MySQL web applications.
Este documento resume los pasos para realizar pruebas de normalidad en dos variables, el peso y las horas de práctica deportiva, y determinar si estas variables están relacionadas mediante una prueba t de Student. Primero se aplican pruebas de normalidad a cada variable y luego una prueba t de Student para comparar medias y verificar si existe una relación entre el peso y las horas de práctica deportiva.
This document discusses three theories of practice that can create change: cognitive change through insight and reframing, emotional change through control and literacy, and behavioral change through modeling and learning by doing. It also lists characteristics of effective change leaders such as vision, risk-taking, learning from others, and creativity. The document emphasizes that change leaders should use active listening to understand different perspectives and influence change by engaging people in the process from the outset and implementing the change. References are provided to further resources on organizational change and leadership techniques.
La panadería ofrece una gran variedad de panes y productos para el desayuno, merienda o antojos, incluyendo panes dulces y salados hechos con harina de masa normal o integral. También ofrece galletas, productos de Coca-Cola, Alpina, Bavaria, leches y snacks. La panadería busca satisfacer las necesidades de sus clientes a cualquier hora del día con opciones frescas y a precios accesibles.
How Startups Can Leverage the Power of Social MediaJennifer Sheahan
This document provides guidance on how startups can leverage social media effectively. It emphasizes the importance of setting measurable goals focused on lead generation and customer acquisition. It recommends determining target audiences, reviewing current marketing efforts, auditing competitors, optimizing social media profiles, creating engaging content, mapping out a clear strategy, and tracking results. Key platforms discussed include Facebook, Twitter, LinkedIn, YouTube, Snapchat, and Instagram. The document stresses testing approaches, engaging audiences through solving their problems, and sharing relevant content from others.
May Oo Khine is a Quality Assurance Engineer at Camusat Myanmar with experience in telecom design and quality assurance. She has a Bachelor's degree in Engineering from Myanmar Maritime University. Her responsibilities include approving construction to specifications, documenting inspection results, and maintaining quality and safety standards. She has several technical certifications and is proficient in AUTOCAD, Microsoft Office, and advanced Excel.
El documento describe una actividad en clase donde los estudiantes trabajan en parejas para familiarizarse con dos textos relacionados con la compañía Lonely Planet. Cada estudiante recibe uno de los textos y se turnan para leer en voz alta y completar los espacios en blanco del texto del otro, sin mostrar el texto ni traducir palabras. Los textos proporcionan información sobre Lonely Planet como la compañía de guías de viaje independiente más grande de habla inglesa y sus operaciones para ayudar a viajeros y generar ingresos.
Este documento presenta información sobre cómo prepararse para entrar al mundo laboral después de graduarse, incluyendo cómo armar un currículum vitae, cómo sortear una entrevista de trabajo, y lo que se debe saber sobre el sistema educativo y previsional en Chile. El documento también cubre la importancia de desarrollar redes de apoyo profesional y participar en encuentros de egresados.
What have you learnt about technologies 6jamiedear
This document discusses various software tools used in creating a magazine, including Photoshop, Prezi, Slideshare, Google Drive, Google, iCloud, and Blogger. Photoshop allowed the creator to develop design skills and produce high quality work. Prezi and Slideshare helped present work creatively. Google Drive facilitated file storage and collaboration. Google supported additional research. Blogger was key for uploading coursework in a professional, organized manner. Overall, these tools enhanced the creator's design process, time management, and presentation of ideas.
We used a Sony camcorder, tripod, iPhone camera, Adobe Premiere software on a PC, and Samsung camera/video recorder to record, take pictures, and edit footage and images for a vox pops interview video and music video. Footage and pictures were taken, uploaded to computers, and edited using Adobe Premiere to cut scenes, add effects, and finalize the videos.
Este documento describe diferentes estrategias para enseñar la suma y la resta a niños. Explica cuatro tipos de problemas aditivos y sustractivos: problemas de combinación, cambio, comparación e igualación. Para cada tipo, provee ejemplos y describe la estructura, incluyendo qué cantidad es la referencia, comparada o desconocida. El objetivo es que los niños aprendan a identificar el tipo de problema y usar la estrategia correcta para resolverlo.
Este documento presenta una introducción a la resolución de problemas matemáticos. Primero, discute las ideas y tendencias actuales sobre la importancia de la resolución de problemas en la enseñanza de las matemáticas. Luego, describe las características que definen un problema en oposición a un ejercicio, y los rasgos que hacen que un problema sea bueno. Finalmente, presenta una guía para seguir al resolver problemas y desarrolla algunas estrategias clave.
El documento presenta varios problemas matemáticos cortos. El primer problema pregunta cuántos deos tendrá el collar de Carmen si tiene 11 deos canutos y 8 deos en forma de caracol.
The document appears to be lyrics to songs from an album titled "Extreme Coarse Of Action! Pt.2". It contains lyrics across multiple songs or verses addressing topics like righteousness, following God's will, rewards, punishment, and living an upright lifestyle. The lyrics are written in a style that repeats phrases like "Anit no need foe" meaning "there is no need for".
This document discusses the development of a new type of lightweight material called aerographite. It has a porous, web-like structure that allows it to be extremely light yet very durable. The aerographite is produced through a unique manufacturing process that turns liquid carbon into an aerogel-like solid. It is expected to have various applications, such as in aircraft and automotive industries, due to its combination of properties.
Metodos de solucion para ecuaciones diferencialesEden Rodríguez
Este documento presenta un resumen de los métodos numéricos para resolver ecuaciones diferenciales. Introduce los métodos de Euler, Euler mejorado y Runge-Kutta para aproximar soluciones numéricamente debido a que muchas ecuaciones diferenciales que modelan sistemas de ingeniería no pueden resolverse de forma analítica. Explica que estos métodos permiten hallar soluciones particulares dadas las condiciones iniciales y requieren que las ecuaciones sean de primer orden.
The document appears to be lyrics for 6 songs titled "Orange Sun!", "Anit Nothin To Trip On!", "I Got Much Love 4 You!", "O.G Murad! Remix:", "Tha Price Of Tha LORD! Pt.1", and "Tha Price Of Tha LORD! Pt.2". The lyrics celebrate being the best and not needing anything or anyone except praise for the LORD to afford nice accommodations.
ITN Productions needed a new digital platform to generate leads, showcase their work, promote content, and enable clients to access video clips. Skylab delivered a fully responsive website that met all of ITN's needs, organizing a wide range of content across devices. The new site allows custom landing pages and pitching tools to be built, replacing reliance on PowerPoint. It provides a unique experience for each client and acts as an industry resource.
The document discusses the history and development of artificial intelligence over the past 70 years. It outlines some of the key milestones in AI research from the early work in the 1950s to modern advances in deep learning. While progress has been significant, fully general human-level AI remains an ongoing challenge that researchers continue working to achieve.
Hermindo nasceu e mora em Anápolis, Goiás. Ele gosta de ensinar e seu ponto forte como professor é ajudar os alunos, embora fale demais às vezes. Os maiores segredos para uma vida feliz para ele são ter saúde e estar cercado por pessoas queridas.
This document discusses user-defined functions in Perl. It provides examples of how to declare functions using the 'sub' keyword, pass parameters to functions, and set default parameters. It also covers calling functions, returning values from functions, and variable scope within functions. The examples show how functions can be used to split code into reusable pieces and pass data between different parts of a program.
This document provides instructions for conducting a buffer overflow attack on a vulnerable C program to alter its execution flow. It explains how functions are called and stored on the stack, and how overflowing a buffer can overwrite the return address to point to attacker-chosen code. The document demonstrates compiling a sample program, running it under a debugger to find addresses, and using a Python script to send an overly long input exploiting the buffer overflow to execute a secret function.
"PHP from soup to nuts" -- lab exercisesrICh morrow
This document provides instructions for setting up a LAMP (Linux, Apache, MySQL, PHP) development environment on Amazon Web Services (AWS) for completing a series of PHP/LAMP labs. It describes launching an EC2 Linux instance on AWS, installing the LAMP stack, and downloading lab code files. The labs cover topics like control structures, data types, input/output, forms, files, cookies, sessions, and regular expressions. Students are instructed to stop their EC2 instance each day to avoid costs when not in use.
This document contains questions and answers about PHP. It discusses PHP variable names, data types, functions like include(), require(), echo and print, arrays, object oriented concepts like inheritance and constants. It also covers regular expressions, error handling, strings, files and directories.
PHP is a programming language used for web development that allows developers to create dynamic content. It is embedded within HTML and is commonly used with databases like MySQL. PHP code is executed on the server side, and the results are sent to the browser as plain HTML, JavaScript, or other code. Some key points about PHP include that it is free, open source, and can be easily integrated with popular databases. It also supports a variety of protocols and has a simple syntax that allows for powerful functions like system calls and form handling.
Shell scripting allows combining command sequences into simple scripts to reduce user effort. It involves writing commands for the shell to execute. Key aspects include variables, special variables, arrays, decision making with conditionals, loops, functions, regular expressions, file/user administration and IO redirection. Common tasks like system monitoring, logging and trapping signals can be automated through shell scripts.
Switch case statements provide an alternative to long if/else statements when comparing a variable to multiple integral values. The basic format compares the variable to case values, executing code for a matching case. A default case handles non-matching values. Loops allow code to repeat, with for, while, and do-while loops. For loops initialize/update a variable and check a condition each repetition. While loops check a condition and repeat until it's false. Loops are useful for repeating tasks like displaying lists of data.
The document discusses programming concepts including programming languages, switch case statements, and looping. It provides examples of how to write code using switch case statements and different types of loops (for, while, do-while). The examples demonstrate how to get user input, perform calculations, and repeat blocks of code multiple times.
This tutorial shows how to develop painless web applications using PHP and Oracle Database 11g. It covers connecting to the database, fetching and displaying data, using bind variables, creating transactions, and more. The document provides code examples for each task and instructions for running the code. It assumes basic PHP knowledge and aims to help developers get started integrating PHP with an Oracle database.
Programming involves using computer languages to develop applications, scripts, or other instructions for computers. It is a creative process where programmers instruct computers on tasks through programming languages. There are many programming languages available, with some of the most common being C++ and Dev C++. Programming can involve various structures like switch statements and loops to control program flow and repetition.
The document discusses programming concepts in Perl including variables, flow control, loops, input/output, and subroutines. It describes three basic Perl data types: scalars, arrays, and hashes. It provides examples of regular expressions, printing hashes, and using filehandles for reading from and writing to files. The document also discusses best practices for Perl programming such as checking for errors, commenting code, and developing programs in stages.
Perl is a programming language that was originally released in 1987. It has become widely used for tasks like CGI scripting, databases, and XML processing. Perl is known as a "glue language" because it can interact with many popular applications.
The Comprehensive Perl Archive Network (CPAN) provides a comprehensive library of Perl extension modules, similar to frameworks like J2EE and .NET. CPAN has helped Perl integrate with other languages like C, C++, and Java.
Perl's strength comes from its active user community which maintains resources like CPAN, documentation sites, and local user groups. Perl powers many popular websites and is often called the "duct tape of the Internet" due to its
The document provides an overview of useful PHP functions for including files, validating user input, and creating custom functions. It discusses the include() and require() functions for including external files. It also demonstrates how to validate user input using functions like strlen(), ereg(), and regular expressions. Finally, it shows how to create custom functions to encapsulate repeated blocks of code and handle errors gracefully.
COMP 2103X1 Assignment 2Due Thursday, January 26 by 700 PM.docxdonnajames55
COMP 2103X1 Assignment 2
Due Thursday, January 26 by 7:00 PM
General information about assignments (important!):
http://cs.acadiau.ca/~jdiamond/comp2103/assignments/General-info.html
Information on passing in assignments:
http://cs.acadiau.ca/~jdiamond/comp2103/assignments/Pass-in-info.html
Information on coding style:
http://cs.acadiau.ca/~jdiamond/comp2103/assignments/C-coding-style-notes
[1] A filter program is a program which reads its input from “standard input” (“stdin”) and writes
its output to “standard output” (“stdout”). Filter programs are useful because they make it easy
to combine the functions they provide to solve more complex problems using the standard shell
facilities. Filter programs are also nice to write, because the programmer doesn’t have to worry
about writing code to open and close files, nor does the programmer have to worry about dealing
with related error conditions. In some respects, filter programs are truly “win-win”.
Write a filter program which uses getchar() to read in characters from stdin, continuing until
end of file (read the man page and/or textbook to see the details on getchar(), or, heaven forbid,
review the class slides). Your program must count the number of occurrences of each character in
the input. After having read all of the input, it outputs a table similar to the one below which, for
each character seen at least once, lists the total number of times that character was seen as well as
its relative frequency (expressed as a percentage). Note that the characters \n, \r, \t, \0, \a, \b,
\f, and \v (see man ascii) must be displayed with the appropriate “escape sequence”. Ordinary
printable characters must be output as themselves. Non-printable characters (see man isprint)
must be printed with their three-digit octal code (see man printf).
You can get input into a filter program (a2p1 in this case) in three ways:
(a) “pipe” data from another program into it, like
$ echo blah blah | a2p1
(b) “redirect” the contents of a file into the program, like
$ a2p1 < some-file
(c) type at the keyboard, and (eventually) type ^D (control-d) at the beginning of a line to
signify end of file.
Your output must look like the following, for this sample case:
$ echo ^Aboo | a2p1
Char Count Frequency
--------------------------
001 1 20.00%
\n 1 20.00%
b 1 20.00%
o 2 40.00%
Note: in the above examples, and from now on in this course’s assignments, text in red is text that
the human types, and a “$" at the beginning of a line like that represents the shell prompt.
1
http://cs.acadiau.ca/~jdiamond/comp2103/assignments/General-info.html
http://cs.acadiau.ca/~jdiamond/comp2103/assignments/Pass-in-info.html
http://cs.acadiau.ca/~jdiamond/comp2103/assignments/C-coding-style-notes
Note that I entered a ^A (control-a, not the circumflex character followed by the capital A) by
typing ^V^A. The ^V tells your shell that you want it to interpret the next character literally, rather
than to use any special meani.
The document discusses programming languages and different types of loops used in programming. It defines programming as using a computer language to develop applications and scripts for a computer to execute. It then describes the different types of loops - for loops, which allow initialization of a variable, checking a condition, and updating the variable; while loops, which repeat code while a condition is true; and do-while loops, which execute code at least once before checking the condition. Examples of each loop type are provided to illustrate their usage.
The document provides an overview of using include files and functions in PHP scripts. It discusses:
1) How include files allow common code to be reused across scripts by importing the contents of one file into another.
2) Useful PHP functions like include() and require() for importing files, as well as examples of validating user input with functions like strlen() and regular expressions.
3) How functions allow code to be reused by defining blocks of code that accept parameters and return values, and examples of creating simple functions.
The document discusses PHP functions for including files and validating user input data before inserting it into a database. It explains the difference between include() and require(), and provides examples of using them to include common code across pages. It also demonstrates how to validate data length and presence using functions like strlen() and conditional statements. The goal is to check user input meets criteria like being a certain length before inserting it into a database to prevent errors.
The document provides an overview of useful PHP functions for including files, validating user input, and creating custom functions. It discusses the include() and require() functions for including external files. It also demonstrates how to validate user input using functions like strlen(), ereg(), and regular expressions. Finally, it shows how to create custom functions to encapsulate repeated blocks of code and handle errors gracefully.
This document provides an overview and steps for a Perl/CGI tutorial. The tutorial will solve the problem of extracting data passed to a program through the Common Gateway Interface (CGI) and constructing an HTML response.
The tutorial assumes familiarity with UNIX but no Perl experience. It breaks the problem down into steps including setting up the Perl framework, printing "Hello World", adding CGI headers, and printing the response in HTML. Later steps demonstrate accessing environment variables passed from the server and data passed through STDIN.
This document provides an overview and steps for a Perl/CGI tutorial. The tutorial will solve the problem of extracting data passed to a program through the Common Gateway Interface (CGI) and constructing an HTML response.
The tutorial assumes familiarity with UNIX but no prior Perl experience. It breaks the problem down into 7 steps: 1) Perl framework and mechanics, 2) Hello World, 3) Hello World from CGI, 4) Hello World in HTML, 5) Echo environment variables, 6) Echo STDIN variables, 7) Perl library. Each step builds on the previous to introduce Perl concepts and features needed to accomplish the task of passing data between a web server and client.
1. PROGRAMMING
59LINUX MAGAZINEIssue 21 • 2002
Perl: Part 3
THINKING IN
LINE NOISE
T
he sample application given here will show how
Perl earned its monikers, the duct tape of the
Internet and the Swiss army chainsaw.
Hopefully it will also illustrate how you can replace
automations currently done with a combination of
shell, sed and awk with a small amount of Perl to
give faster, more coherent solutions.
In addition to reinforcing old ground the
example presented here also touches
upon some aspects of Perl that we
have not yet
covered; such as regular
expressions. Rather than
introduce each portion of the
language in a piecemeal month-by-
month fashion this approach enables you to start
learning the language the right way: by using it. Over
the coming months we will then focus on a more in-
depth coverage of the new topics we introduce in
this way.
The short application presented here as Example 1
is an example of a glue script: a Perl script that uses a
standard command to do a lot of its work for it;
maintaining simplicity in the Perl code, while bringing
additional functionality to the command.
Having introduced the basic elements of Perl over the past two issues,
Dean Wilson and Frank Booth now explain how to
combine many of the elements shown
previously into a complete program
that you can run and tinker with
Example 1: count_logins.pl
01 # Sample script to count the number of logins a user has.
02 # Uses the ‘who’ command to get the user details.
03
04 #Location of the external binary.
05 my $whobin = “/usr/bin/who”;
06
07 # Separates the command from its path
08 # and assigns the command name in $cmd.
09 my $cmd = (split(“/”, $whobin))[-1];
10
11 # Sanity check to ensure external dependencies are met.
12 die “No $cmd command found at ‘$whobin’n” unless –e $whobin;
13 die “The $cmd command at ‘$whobin’ is not executablen” unless –xU
$whobin;
14
15 my %usertally = getusers($whobin);
16
17 while (my ($user, $numlogins) = each %usertally) {
18 print “$user has $numlogins login”, $numlogins > 1 ? “s” : “”, “n”;
19 }
20
21 sub getusers {
22 my $whobin = shift;
23 my %user;
24
25 #Open a pipe to read response in from the ‘who’ command
26 open(WHO, “$whobin |”) || die “Failed to open who: $!n”;
27
28 # loop over the output from who, assigning the line to $_
29 while (<WHO>) {
30 next if /^s*$/; #Skip all empty lines
31 chomp;
32 m/(w+)s/;
33 $user{$1}++;
34 }
35
36 close WHO;
37 return %user;
38 }
2. File handle refresher
PROGRAMMING
60 LINUX MAGAZINE Issue 21 • 2002
comprehensive documentation (and you do write
comprehensive documentation don’t you?) you may
be better served looking at POD, a subject we will
cover in a future column.
Line 5 starts the actual code, we assign the full
path of the external who command to $whobin. This
is done both to avoid any path problems we may
encounter if we assume the running user has a valid
path set up and to allow us to do some checking on
the state of the file at the given location.
In line 9 we try to establish the name of the binary
we are calling so that we can tailor any error
messages we emit to show which command the
problem occurred with. When writing error messages
a little extra work upfront can save hours of head
scratching once you begin to create bigger
applications. The split command takes the path and
command name we assigned to $whobin and
separates them based upon the first argument given.
We then use a negative subscript (which works in the
same way as the array subscripts in article one) to
return the last item (the –1; which means count back
one from the end) from the split, which is the
command name and assign it to $cmd.
The sanity checks in lines 12 and 13 confirm that
the file indicated by $whocmd is both present and
executable. If either of these criteria fails then the
program aborts with an error message detailing the
problem.
Line 15 is where we encounter our custom
subroutine, getusers which has its code in 21–38. We
call the getusers subroutine with the location of the
who command as its only argument and we assign its
An enhanced version of this command, which runs
continually and notifies you of any changes in the
number of logins on the system, can be found in the
/Perl directory on this month’s CD with the name
whoson.pl. This version has more functionality and
makes a good demonstration of how to apply some
of the theory we discuss in this article.
The count_logins.pl script, shown in Example 1,
uses a surprising variety of Perl functionality
considering its small size. The script is started with a
short description of its intended functionality.
Depending on whether you are coding for your own
benefit or for a more public audience you could add
more details such as a created and last modified date,
an email address for author contact and any other
short details that a user may need. For more
a little
extra work
upfront can
save hours In last month’s article we dipped our toes in to
Perl’s file handling commands and showed how to
open a file for reading and writing. Due to the
large role file handles play in most programs, here
is a brief recap on opening, writing to and closing
a file handle:
open (HANDLE, ‘>afile’) || die “$Failed to U
open HANDLE: $!n”;
print HANDLE “Hellon”;
close HANDLE;
The example opens the file “afile” in the current
directory for output – clobbering the contents of
any existing file of that name. We then use the
common Perl idiom to test whether the open file
operation is successful. If it fails then the die
function is called, exiting the program and printing
the error message given and setting the return
code. In the string passed to the die function we
also pass $! – another of Perl’s internal variables.
When used in string context $! reports the system
error string related to the last command.
If the open was successful we carry on to the
next line and then print the line “Hellon” to afile.
After printing the line the file is closed and the
program exits. It is possible to check the return
value of the closing of the file handle but in this
example we gain nothing from it, as there is
nothing we can check.
We then moved on and covered alternate ways
of initialising the handle to allow us different ways
of interacting with it:
* ‘<’ – Read from a file.
* ‘>’ – Over-write or create the file.
* ‘>>’ – Create a file if none exists, append to a
file if it does.
If no prefix is specified the default is ‘<’.
3. Introduction to IPC and piping
PROGRAMMING
61LINUX MAGAZINEIssue 21 • 2002
return value to the %usertally hash for our future
use.
At this point we will make a leap to line 21 and
have a closer look at what is happening in the
subroutine that will give us the return value. We
declare the subroutine with the sub keyword
followed by the name of the subroutine and then an
optional prototype. We will cover sub in a future
article, or the impatient can take a look at perldoc
perlsub. We then follow this with a curly brace to
show we are starting the body of the sub.
In line 22 we assign the location of the ‘who’
command that we passed in to the subroutine in to
the $whobin variable using the shift function. You
may remember the shift function from our earlier
encounter with it in article one when we used it to
remove and return to us the first element of an array.
In Perl, subroutine arguments are accessed via the
@_ array – an implicit variable and a relative of $_
– that you will be seeing more frequently from this
point on. When you pass multiple scalars (variables
with a single value and visually represented with a
‘$’) to a subroutine each call to shift returns the
next one in the array while removing it. This is one
of the methods of iterating through subroutine
arguments.
We then create the hash that is to hold the users
on the system and the number of logins they
currently have running before moving on to a variant
of the file open we saw last month. Line 26 with the
piped file open is explained in the Introduction to IPC
boxout.
One of the important design considerations for
programs that “pipe out”, have other interactions or
dependencies with external commands, or that utilise
other forms of IPC is that of blocking. When you
invoke an external command and attempt to read in
its results your program will halt until the IPC or pipe
duct
tape of
the
Internet
In the count_logins.pl script (in the main body of
the article) we open a file handle as a pipe to an
external system command. In order to understand
how this works you will need a basic understanding
of file handles, if you are unsure then please read
the Filehandle Refresher boxout before continuing.
Opening a pipe to an external command can be
considered one of the more basic forms of
Interprocess Communication. Interprocess
Communication, or IPC as you’ll often see it
referred to, is a way that multiple processes can
communicate with each other. This communication
can range from merely knowing that an event has
occurred, known as “signal handling” to sharing
the output of one process with another on the
same host, the same network or even across the
Internet.
In the example script, count_logins.pl, the pipe is
opened to the who command as shown below:
open(WHO, “$whobin |”) || die “Failed to U
open who: $!n”;
The who command is executed and if it is successful
then its output is available for reading from the
WHO file handle in the same manner as if the
handle referred to a plain text file. This simplicity in
gathering the output of external commands is one
of the main contributors to Perl’s title of duct tape
of the Internet. Taking this premise slightly further
we can use the same syntax to set up whole
pipelines of commands external to the Perl script.
These chains eventually return the output of the last
command in the chain. This behaviour fits in so well
with the standard Unix ideal of filter chains that
many people never advance beyond this form of
IPC.
Now that we have shown how to read data in
from an external command it seems fitting to show
how easy it is to reverse this and send output from
a Perl script to an external application:
open(PAGER, “| $pager”) || die “Failed to U
open $pager: $!n”;
If you are curious as to Perl’s other forms of IPC
then ‘perldoc perlipc’ is a good place to start and
Lincoln Stein’s Network Programming with Perl is an
excellent title that covers the subject in an unrivalled
depth.
4. PROGRAMMING
62 LINUX MAGAZINE
has returned the data that is to be read. If not
recognised and catered for this can have many
negative effects on your program. A common
example is the user prematurely terminating the script
from the terminal, leaving any external resources it
uses in an undermined state or interrupting the
program in the middle of a series of actions that
must either all be completed or none completed (this
is known as atomic). A common way to deal with this
in Perl on Linux is to use signal handlers to protect
critical parts of your program and allow them to exit
gracefully.
Another more advanced use of signals to help
mitigate the problems of blocking is with the alarm
function – full details of which can be found in
perldoc –f alarm, and a custom signal handler but
due to its advanced nature we will return to this at a
future point when we cover different IPC
mechanisms.
With line 29 we begin to get the data in from the
WHO handle and process it to give us our totals. We
set up a standard while loop which will iterate over
the file handle assigning the line read in to $_ until
no more data is left. This was covered in article two
if you need a refresher.
On line 30 we get our first view of a regular
expression. A regular expression (regex) is a way of
expressing a desired set of text to match using
special meta-characters. While this explanation may
seem less than enlightening regular expressions play
such a large part in Perl we will cover them in great
depth in a separate article. This regex is a simple one
and has been placed just to whet your appetite.
Breaking down the regex we have a forward slash
that indicates that anything between it and the next
un-escaped forward slash is the target we wish to
match. The ^ indicates that the regex should be
checked from the start of the string and the $
indicates the end of the string.
The s is called a character class and represents the
Issue 21 • 2002
Linux signals and signal handlers
you can
write your
own custom
signal
handlers
Events can happen at any point while a process
runs: the operating system may terminate the
application, file handle limits can be reached or
the user may simply get tired of waiting and press
Ctrl+C.
When one of these occurs a signal is sent to
your program and it responds by taking an action
such as immediately halting execution and exiting
or rereading its configuration. To get a list of the
signals Linux supports you can type kill –l at the
command prompt.
While the default responses to signals can be
enough to ensure that the program does the
minimum of what’s required, they can also cause it
to exit in an incomplete state creating problems
such as leaving temporary files on the machine or
even just prevent it from logging the time the
program stopped.
To get around some of these limitations you can
write your own custom signal handlers to catch
and process the signals as you see fit. Overriding
signal handlers in Perl is simple, the %SIG hash
can have references to user-defined signal handlers
(subroutines by another name) that are called
when Perl receives the corresponding catch-able
signal.
$SIG{INT} = sub { print “I got killedn”; U
exit; };
while (1) {
print “Still heren”;
sleep 2;
}
In the above code snippet we enter an infinite
loop that simply prints the same string until you
get bored and press Ctrl+C. This then sends an INT
signal to Perl, causing Perl to stop the section of
the code it’s currently executing and call the
handler assigned to INT. While this example is
slightly contrived, if you remove the exit in the
handler the program does not terminate on a
Ctrl+C and this is one example of how you could
protect sections of the code that need to complete
from being killed while running.
5. PROGRAMMING
63LINUX MAGAZINEIssue 21 • 2002
different forms of whitespace (including spaces and
tabs) while the asterisk is similar to a wildcard and
means zero or more of the expression preceding it.
Putting these together we end up with code that says
“If the line from start to finish is empty or comprised
only of whitespace then do not process this line and
jump to the next.”. While this example may not be
crystal clear if you have no previous exposure to
regexs hopefully it has shown how terse yet powerful
they can be when used correctly.
Still operating on the implicit $_ we remove the
new line from the end of the string (Using the chomp
on line 31) and then we work another bit of regex
magic on line 32. This time we use a character class
that represents words. A word in this context is a
letter in the ranges of a-z or A-Z. A number in the
range 0-9 or the underscore (‘_’). We match as many
word characters as we can from the start of the line
up until the first piece of whitespace we encounter,
using s again, as described above. The parentheses
are another regex meta-character, known as
capturing or grouping depending on the context they
are used in. They cause the value matched by the
regex expression inside them to be assigned to one of
the special regex match variables, in this case it gets
assigned to $1 as it is the first match so that we can
use the text matched outside of the regular
expression.
In line 33 we use a Perl idiom that you will see in
the wild. If we matched a new user name on line 32
it will not yet be present in the $user hash. We then
add the user to the $user hash and increment the
number of times we have seen that user by one. In
order to understand why this is successful you must
remember that when an empty string is used in
numeric context it is a zero, we then increment the
zero by one and have the correct number of logins –
one login. If the user is already in the $user hash the
++ ups by one the number of logins as expected. This
is an oft-used idiom as it reduces a four line
operation to one cleaner line of code.
We then act like responsible coders and close the
WHO handle at line 36 – even knowing that implicit
closes will occur it’s good practice to close them
manually. We then return the %user hash to line 15,
where we called the subroutine, and where the
values are assigned to %usertally and we finish the
subroutine with the closing curly brace.
Jumping back up to line 17 we iterate through
each of the key and value pairs in the hash with a
while loop and in the body of the loop print out the
user and the number of logins they had.
The last interesting example of Perl code in this
small application is at line 18. When we list the
number of logins the person had we want to say
‘dwilson had 1 login’ or ‘dwilson had 2 logins’ with
the s added to the end of the string for anything
more than a single login.
We do this by building a longer string from
composite strings and including a ternary operator.
The building of the string is achieved by passing a list
of arguments to the print function with each
argument separated with a comma. The ternary
operator (also called the trinary operator in some Perl
books) is in essence a shorthand if-then-else
statement. It is actually an expression, so it can be
added in places such as function calls where an if
statement is not permitted.
A ternary maps out like this:
condition ? then : else
$numlogins > 1 ? “s” : “”
So if $numlogins is greater than one, meaning the
condition is true, then the then part is called and an s
is added to the string. If the condition evaluates to
false the else part is called and, seeing as, in this case
we not do wish to add anything, we return an empty
string.
In closing
Now that you have seen a complete, albeit, small
example of a functional Perl script, the more abstract
concepts that were covered in the first two articles
should be better understood now. We have lightly
touched upon subroutines and regular expressions
and handed out some pointers on further reading for
those eager to move ahead before we come back to
them in the near future.
Source code
The source code for the examples used in this article
can be found on this month’s cover CD in the /Perl
directory.
another
bit of
regex
magic