Programmation
670 documents à télécharger gratuitement
Cours, examens, TD, TP et exercices de programmation. Thèmes couverts : algorithmique, langage C, Java, Python, POO, structures de données.
The document contains exercises for using a Python interpreter focusing on basic mathematical operations and operator precedence. It requires the user to input various expressions and analyze their outcomes. Additionally, it emphasizes understanding the rules of operation priority in mathematical calculations.
This document explores operations with strings and dates in R programming. It covers techniques such as character counting, case conversion, string splitting, and substring extraction, along with date manipulation using UNIX time and various R functions. Examples demonstrate formatting adjustments, date operations, and leveraging built-in utilities for real-world scenarios. Finally, it introduces regular expressions for advanced text pattern matching in datasets like email domains.
This document covers the fundamental control structures in R, including conditional statements and loops. It provides examples of using 'if', 'for', and 'while' statements, as well as logical and comparison operators. The document also introduces functions in R and how to define user-defined functions.
This course covers the fundamental principles of the programming language, focusing on mathematical operations, variable assignment, and character strings. It includes modules on basic operations, vector creation, and the use of factors in data management. The course is designed to provide practical skills in programming and a solid understanding of data structures.
This document provides an introduction to the Java programming language, covering fundamental concepts such as program structure, variables, control statements, and loops. It emphasizes the object-oriented nature of Java and explains how to set up a Java development environment. Sample code snippets and methods are provided to illustrate the principles discussed.
This document provides an introduction to Object-Oriented Programming (OOP) aimed at second-year Business Computing students. It covers the basic concepts of OOP, including classes, objects, encapsulation, inheritance, polymorphism, abstract classes, and interfaces, particularly using the Java programming language. The course also addresses procedural programming limitations and emphasizes developing applications using an object-oriented approach.
Academic document imported into UniversityLib: Programmation Multimédia.
MODULE : POO Enseignant : Mohamed Kharrat Ann e universitaire 2016/2017 1 S ance 5 C++ : classes Introduction aux Langages Orient s Objets Qu est-ce qu un objet ?
MODULE : POO Enseignant : Mohamed Kharrat Année universitaire 2016/2017 1 Séance 3 Arguments par défaut définition : void fonction(int a, int b, int c) { cout << a << "," << b << "," << c; cout << endl; return; } • prototype : void fonction(int, int =0 , int =1 ); 2 Arguments par défaut utilisation : void main() { int x,y; x=4; y=x+5; fonction(y); // fonction(y, 0,1 ); fonction(2,x); // fonction(2,x, 1 ); fonction(x,y,x+y); // 3 arguments } 3 Arguments par défaut Cas particuliers, attention danger En C++, on ne peut pas « sauter » des paramètres, même s'ils sont facultatifs.
MODULE : POO Enseignant : Mohamed Kharrat Ann e universitaire 2016/2017 S ance 1 Le langage C++ est un des langages les plus c l bres au monde. Tr s utilis , notamment dans le secteur des jeux vid o qui appr cie ses performances et ses possibilit s, le C++ est d sormais incontournable pour les d veloppeurs.
Chapitre IV - Les files d’attente Définition d’une file La file est une structure de donnée, qui permet de stocker les données dans l'ordre FIFO (First In First Out) - en français Premier Entré Premier Sorti).
27/12/2014 chapitre 3 : les pointeurs Chapitre 3 Les pointeurs Toute variable manipul e dans un programme est stock e quelque part en m moire centrale. Cette m moire est constitu e d'octets qui sont identifi s de mani re univoque par un num ro qu'on appelle adresse .
1- Notions de la POO Un objet est une entité qui est composé de membres ; parmi ces membres, on dispose de champs (les variables qui lui sont caractéristiques), de méthodes, de propriétés, ➢ Un objet est créé selon un modèle qu'on appelle une classe (la famille des objets).
This document provides an overview of UDP programming in Java, emphasizing its characteristics and methods for sending and receiving messages. It illustrates the construction of datagram packets and the usage of DatagramSocket for communication. Additionally, it covers multicast messaging for broadcasting to multiple machines.
Ce document présente une série d'exercices sur la programmation linéaire en nombres entiers. Les exercices incluent des problèmes classiques tels que le problème du sac à dos, les problèmes d'affectation, et d'autres cas d'application pratique. Chaque exercice propose des formulations et des techniques de résolution.
This document provides an overview of Enterprise Java Beans (EJB), a technology used for developing reusable Java components. It discusses the architecture of EJB and its components, emphasizing their utility in creating distributed applications. Various types of EJB and their lifecycle management are also detailed, highlighting their roles in enterprise-level software solutions.
This document introduces fundamental concepts of distributed computing, including system models, synchronization, fault types, and coding conventions. Key principles such as election, diffusion, mutual exclusion, and deadlock detection are explained, with algorithms like Le Lann's election algorithm and Ricart-Agrawala's mutual exclusion protocol detailed. The material also discusses practical implementation aspects using distributed architectures. Exercises and solutions are provided alongside theory, with sections marked for deeper exploration of advanced topics.
Ce document présente une introduction à l’algorithmique répartie, couvrant les modèles de systèmes répartis et les algorithmes associés. Il traite des concepts clés tels que la précédence causale, les algorithmes de diffusion et l'exclusion mutuelle. Des exercices sont inclus pour renforcer la compréhension des sujets abordés.
This document focuses on exercises related to distributed systems and their coordination mechanisms. It introduces scenarios involving termination algorithms in a 5-site system, token-based mutual exclusion with specific entry orders to critical sections, and permission-based mutual exclusion following priority rules. Each problem provides initial conditions and specific configurations to solve concurrency control challenges efficiently.
This document introduces Java EE as a platform for developing distributed enterprise applications. It discusses the architecture of n-tier applications, focusing on the separation of presentation, business, and data layers. Additionally, it covers the key APIs of J2EE, including components, infrastructure services, and communication services.
This document provides a comprehensive guide on Java Applets, explaining what they are, their lifecycle methods, and how to create and execute them within a web browser. It outlines the important methods associated with Applets and offers a sample code structure for building a basic Applet.
This document presents a lab exercise on pointers in C. It includes tasks for memory allocation, array processing, and manipulation of dynamic structures. Various exercises aim to reinforce understanding of pointers and dynamic memory management.
The document introduces the implementation of a Java class to model bank accounts, focusing on the principles of encapsulation and object-oriented programming. It specifies account attributes, including account number, holder's identity, balance, and constraints such as overdraft limits and maximum allowed withdrawals. The methodology requires defining constructors, accessors, modifiers, and custom methods like overdraft checks, deposits, withdrawals, and account transfers. Finally, the exercise includes testing functionalities using a companion testing class to validate specified behaviors...
Ce document traite des principes de séparation entre l'interface utilisateur et l'application pour favoriser la modularité. Il aborde également les concepts de systèmes interactifs et les architectures logicielles comme MVC. Enfin, des règles pour la spécification des interfaces graphiques sont proposées.















