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.
This document covers array data structures in a server-side programming syllabus. It explains the declaration and initialization of arrays, including associative ones, with detailed examples and syntax. Additionally, the document discusses methods for traversing arrays and provides a comprehensive list of functions for array manipulation, such as sorting, merging, and searching. The use of arrays for data structuring and function alternatives for accessing array elements are also highlighted.
This document provides an introduction to advanced operating systems. It specifically focuses on the use of the Make tool for automating the compilation of software projects. The document includes examples of makefile usage for compiling C programs.
Ce document présente l'environnement Java, un langage interprété utilisé pour la programmation orientée objet. Il explique le processus de compilation du code source en bytecode et son interprétation par la machine virtuelle Java. Il fournit également des exemples de commandes de compilation et d'exécution des programmes Java.
Ce document présente le support de cours du module «Programmation orientée objet (POO)», s'adressant aux étudiants de 2ème année Licence Fondamentale et appliquée en Informatique de Gestion à l’université de la Manouba. Il couvre les principes fondamentaux de la programmation orientée objet ainsi que les concepts de base d'un programme Java. Ce cours est structuré en plusieurs chapitres, chacun abordant des aspects essentiels de la POO et de l'environnement Java.
Ce document détaille les étapes pour concevoir une boîte de dialogue permettant l'acquisition et la modification des informations des membres d'un club sportif. Une structure de gestion du panneau est mise en place avec BorderLayout et subdivisée en sous-panneaux gérés par des GridLayout et FlowLayout pour les composants comme les labels, champs de texte, boutons radio et cases à cocher. Une mise en œuvre en Java Swing est démontrée, avec un tableau de JCheckBox pour représenter les sports disponibles. L'intégration des gestionnaires de disposition et des composants est expliquée pour une i...
This document contains an exam for the Ecole Nationale des Sciences de l’Informatique, focusing on algorithmic approaches to numerical analysis and differential equations. It presents multiple exercises requiring the application of Lagrange polynomials, Newton's method, and numerical integral approximation techniques. Additionally, it includes a practical application of Newton's law of cooling in forensic analysis.
This document introduces JDBC (Java Database Connectivity), a framework for accessing relational databases in Java applications, irrespective of the database type. It covers the step-by-step process of connection, query execution, and transaction management using java.sql and javax.sql packages. Practical examples illustrate simple and parameterized SQL queries, updates, and result set handling. Advanced topics include transaction management and error handling using SQLException.
This document details the development of graphical user interfaces (GUIs) in Java using Swing. It covers a case study involving the creation of an authentication system with login and sign-in functionalities. The methodology includes designing the interface, implementing database connection using MySQL, and handling user interactions with validation mechanisms. The document also provides code examples for database connectivity, user authentication, and CRUD operations for managing student information.
This document discusses a research project conducted at the CRISTAL-GRIFT laboratory to obtain a diploma in computer engineering. The main objective was to propose an algorithm for indexing 3D objects, which is based on an intrinsic local shape descriptor. The final outcome included the implementation and testing of a 3D object retrieval platform.
This document guides users through building a graphical user interface (GUI) in Java using Swing and managing user authentication via MySQL database integration. The methodology involves designing an interface, coding its components, implementing functionalities like login and sign-up buttons, and data validation. Users are instructed to connect to a MySQL database to store and retrieve user information effectively. The document provides step-by-step instructions, including sample code for database connection and handling user authentication.
This document provides comprehensive coverage of Java Swing, a graphical user interface toolkit supported by Oracle. It distinguishes Swing from the obsolete AWT and explores components, containers, and layout management for building user interfaces. The information delves into event management, listener patterns, and gives examples including code demonstrating interactive user interface construction. The document emphasizes different implementation styles like version-based approaches, classes imbriquées, and anonymous inner classes to simplify or optimize GUI development.
This exercise involves creating a simple Java program to display a window that tracks and displays the number of mouse clicks on it. The solution provided defines a `Fenetre` class, which extends `JFrame` and implements `MouseListener` to handle user interaction. A `JLabel` updates dynamically to show the click count, and the main class `TesterNombreClics` initializes and displays the window. The program effectively demonstrates event handling and GUI design principles in Java.
This document provides an introductory syllabus on .NET Framework and its components, focusing on Visual Basic.NET for software development. It covers foundational concepts such as integrated development environments (IDEs), framework architecture, and key programming constructs like variables, data types, and object-oriented principles. Additionally, it explains the role of Visual Studio as the primary IDE for developing various types of .NET applications, including Windows, web, and mobile applications. Detailed discussions on advanced features, such as Base Class Libraries, string manipu...
This document provides a deep dive into implementing object-oriented programming concepts using VB.Net. It starts with basic definitions and principles of object-oriented paradigms such as encapsulation, inheritance, and polymorphism. The guide outlines the creation and management of classes, including constructors, destructors, and accessors, and introduces advanced topics like abstract classes, interfaces, and method overloading. Practical exercises challenge the reader to implement various classes like Salarie and Commercial for real-world applications, ensuring a hands-on understanding...
This document explains the development of a C# application to handle element transfer between two lists using various user interfaces facilitated by a TabControl component with four TabPages. It offers functionality for single and multiple selections in ListBox and CheckListBox controls, alongside features embracing 'drag-and-drop' capabilities. Buttons are provided to add, remove, clear, and transfer elements between the lists. Key C# properties and methods related to ListBox operations, as well as Drag-and-Drop event handling, are described in the annex for reference.
This document explores Java's generic programming capabilities and their application in collections. It introduces key concepts like generic types and interfaces, showcasing their importance through hands-on exercises such as implementing stacks (using both arrays and linked lists), creating complex tasks with hierarchical structures, and managing contact directories via HashMaps. The methodology focuses on transforming existing code into generic implementations, using Java's core collection frameworks to emphasize the extensibility and type safety of generics. The findings highlight practi...
This document serves as an exercise-based revision guide to strengthen programming concepts. It discusses exception handling using Java, addressing methods like parseInt and custom exception creation. The exercises focus on implementing and testing custom exceptions in classes like 'Entreprise' and its derivatives, as well as practical usage of the 'Toutou' class constructor with validations. Additionally, it introduces abstract classes with 'TabTrie', discussing inheritance, sorting, and the use of exceptions within data structures.
The document outlines instructions for creating and manipulating various Java collections such as ArrayList, Vector, LinkedList, and HashMap. It provides a step-by-step methodology for initializing, populating, displaying, sorting, and traversing these collections. Specific methods such as addFirst, addLast, and deletion processes are covered. The document emphasizes practical implementation through a Java project structure and test class development.
The document introduces the concept of genericity in Java and demonstrates its application using collections such as LinkedList and ArrayList. It provides step-by-step exercises to implement generic stacks, using interfaces and extending key Java classes like Collection and LinkedList, for better type-safety and reusability. The exercises also cover implementing generic tasks and building a phonebook using HashMaps, emphasizing the importance of data structures with type parameters. Each task highlights practical code examples and challenges to learn about Java's generics and collections API.
This document explores the concept of generics (parametric polymorphism) in Java. It starts with motivating scenarios for handling different data types in collections, emphasizing issues like code duplication and runtime errors. It contrasts early Java approaches (pre-1.5) with modern generic programming introduced in Java 1.5, demonstrating increased safety and reusability. The document delves into technical features such as type erasure, parametrized classes, and limitations like shared static members and runtime type constraints. Finally, it emphasizes the robustness and simplicity gener...
This document provides a detailed explanation of Java's collection framework, covering interfaces such as Set, Map, and List, alongside their implementation classes like ArrayList, LinkedList, and TreeSet. It illustrates concepts like generics, iteration, and operations such as add, remove, and contains, emphasizing the use of methods for object handling. Examples with code snippets demonstrate the practical application of collections using Java syntax, detailing specific properties, advantages, and use cases for different collection types. Furthermore, implementation strategies and efficie...
The document serves as a step-by-step practical guide for working with Java collections, including ArrayLists, Vectors, LinkedLists, and HashMaps. Each section provides instructions for creating and manipulating data structures, such as adding elements, iterating, sorting, and using specialized methods like addFirst and addLast for linked lists. Additionally, the HashMap section introduces key-value pair manipulation and search techniques, emphasizing systematic output for observation. Overall, the methodology highlights iterative and customizable development practices for advanced object-o...
This document introduces the fundamental principles of object-oriented programming, focusing on concepts such as objects, classes, inheritance, encapsulation, and polymorphism. It highlights the benefits of modularity, reusability, and abstraction in software design. Various examples, including UML notation, abstract classes, and interfaces, are used to elucidate key programming techniques. The material emphasizes best practices like distinguishing inheritance from association and adhering to design patterns for scalable architecture.
This document explores event-driven programming as a distinct paradigm, emphasizing its non-linear execution model. It defines core principles, such as reacting to generated events and processing them via listeners and queues. The implementation of events often relies on observer patterns or notification models. Furthermore, the Model-View-Controller (MVC) architecture is explained for managing applications with user interfaces, enabling modular development and decoupling of components. The benefits include simplified development workflows, modular task assignments, and enhanced adaptabilit...



















