Lecture

Functions and state

In course
DEMO: pariatur et
Adipisicing culpa aliqua laborum nostrud voluptate laborum ullamco qui aliqua ipsum dolor exercitation ad. Adipisicing velit excepteur consectetur consequat quis laborum ad ex dolore voluptate in. Incididunt cupidatat velit do pariatur. Est laborum eiusmod duis anim aliquip irure excepteur dolore sint irure aliquip non. Officia labore ullamco fugiat pariatur ut tempor dolor qui ea id mollit.
Login to see this section
Description

This lecture introduces the concept of functions and state in programming. It starts by discussing the substitution model and how programs can be evaluated through rewriting. The importance of rewriting in functional programming is highlighted, showcasing how different rewritings can lead to the same solution. The lecture then delves into stateful objects, explaining how objects with state change over time and how mutable state is implemented using variables. Examples of state in objects, such as a bank account, are provided along with their corresponding implementations. The lecture concludes by exploring the relationship between statefulness, variables, and object-oriented programming.

Instructors (2)
incididunt Lorem
Ullamco deserunt enim reprehenderit sit aliquip id qui voluptate aliquip anim. Ea amet anim ut est. Aute est laboris mollit aute cillum officia aute duis esse laborum mollit.
cillum in elit
Officia veniam dolore nulla cupidatat dolore irure. Esse sint enim ut ad sint et est Lorem eiusmod labore eiusmod. Sunt est in pariatur qui sint proident ad dolore incididunt nulla dolor. Deserunt nostrud ullamco irure in cillum reprehenderit aliquip qui aliqua ullamco occaecat.
Login to see this section
About this result
This page is automatically generated and may contain information that is not correct, complete, up-to-date, or relevant to your search query. The same applies to every other page on this website. Please make sure to verify the information with EPFL's official sources.
Related lectures (32)
First Steps with Stainless
Introduces Stainless, a verifier for Scala, emphasizing bug prevention and library access.
Abstract Data Structures and Standard Libraries
Covers abstract data structures and the C++ standard library, including linked lists, stacks, queues, and complex numbers.
Programming Paradigms: Functional, OOP, Polymorphism
Explores programming paradigms like procedural, functional, and OOP, with examples in Python.
Operator Overloading in C++
Explores operator overloading in C++, emphasizing class manipulation and code compilation.
Object-Oriented Programming: Polymorphism and Pointers
Explores object-oriented programming concepts like polymorphism and pointers in C++.
Show more

Graph Chatbot

Chat with Graph Search

Ask any question about EPFL courses, lectures, exercises, research, news, etc. or try the example questions below.

DISCLAIMER: The Graph Chatbot is not programmed to provide explicit or categorical answers to your questions. Rather, it transforms your questions into API requests that are distributed across the various IT services officially administered by EPFL. Its purpose is solely to collect and recommend relevant references to content that you can explore to help you answer your questions.