# Dave Thomas - Simplify Logic With State Machines (Highlights) ![rw-book-cover|256](https://substackcdn.com/image/fetch/$s_!Aq0T!,w_1200,h_600,c_fill,f_jpg,q_auto:good,fl_progressive:steep,g_auto/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9636a529-1646-4498-b782-4d74c85e245d_1024x1024.png) ## Highlights - The actions could return either new state values or an event. If an event is returned, the code will immediately perform another transition using it. ([View Highlight](https://read.readwise.io/read/01kdce0h181ayp63erfvcdm8pa)) ^969898480 - Let’s start with a generous definition: an event occurs when information becomes available to your code. ([View Highlight](https://read.readwise.io/read/01kdce15nw5y6hhrp05fn2xhdr)) ^969899026