Skip to main content

Questions tagged [state-machine]

A state machine is a model for designing systems which change based upon their current state and what input they receive.

7 votes
1 answer
915 views

I know there are several implementation of FSM in C++ containing different set of features and written in different styles. Nevertheless, I've decided to write my own. Here are some key points : c++...
LRDPRDX's user avatar
  • 941
2 votes
1 answer
190 views

I tried implementing a lexer in rust that peeks ahead at the next character and makes a decision based on that. However, i am told that this is bad practice, and instead i should be using finite-state-...
xxxxxxxxxx's user avatar
1 vote
1 answer
116 views

A while ago, I wrote a small Rust crate for parsing & generating URLs for GitHub repositories in various formats (HTTPS, SSH, git://, etc.), with the parsing done using regular expressions with ...
jwodder's user avatar
  • 402
0 votes
1 answer
151 views

In Dungeons and Dragons, we have many spells, e.g. the Charm spell to get anyone to do what you want, the Web spell to entangle someone, the Invisibility spell to make yourself invisible (but once you ...
prestokeys's user avatar
  • 1,401
2 votes
2 answers
286 views

In my quest to search or develop the 'perfect' state machine I have built the following class. With the class you can make a state machine object which comes with timing and transition methods. Being ...
bask185's user avatar
  • 128
8 votes
1 answer
616 views

There are already many Tic Tac Toe posts. But as far as I can tell, none of the ones in Haskell are complete with a GUI Here is my implementation with Gloss. Gist Link for convenience ...
Agnishom Chattopadhyay's user avatar
2 votes
1 answer
264 views

I tried implementing a state machine in C. This is for a Stratosphere Balloon and I wanted to use a state machine to make it better. This will be later implemented in ARM CMSIS. The state function ...
moonraccoon's user avatar
3 votes
1 answer
114 views

I tried to parse command line arguments. The program requires four arguments. I iterate over the arguments. If the argument is an option, I process the option. Otherwise the argument is one of the ...
ceving's user avatar
  • 483

15 30 50 per page
1
2 3 4 5
9