1
0

」 feat: finished ex01

This commit is contained in:
2025-06-03 15:57:15 +02:00
parent de9bd7ed8d
commit 6b00e95da9
5 changed files with 193 additions and 0 deletions

26
ex01/main.cpp Normal file
View File

@ -0,0 +1,26 @@
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* main.cpp :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: adjoly <adjoly@student.42angouleme.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2025/06/03 11:58:43 by adjoly #+# #+# */
/* Updated: 2025/06/03 15:54:55 by adjoly ### ########.fr */
/* */
/* ************************************************************************** */
#include <RPN.hpp>
#include <exception>
int main(int ac, char **av) {
if (ac > 1 && ac < 3) {
try {
rpn(av[1]);
} catch(std::exception &e) {
std::cerr << e.what() << std::endl;
}
} else {
std::cerr << "Error" << std::endl;
}
}