Advertisement
Guest User

Untitled

a guest
Sep 23rd, 2017
59
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.52 KB | None | 0 0
  1. #pragma once
  2. #include "../../RPN/RPN/RPN.h"
  3. #include <iostream>
  4. #include <stack>
  5. #include <string>
  6.  
  7. struct OperationChild : Operation {
  8.     const static char LEFT_ASSOCIATIVITY  = 'l';
  9.     const static char RIGHT_ASSOCIATIVITY = 'r';
  10.  
  11.     const static char OPEN_BRACKET  = '(';
  12.     const static char CLOSE_BRACKET = ')';
  13.  
  14.     static int  getPriority(const char& op);
  15.     static char getAssocitivity(const char& op);
  16. };
  17.  
  18. class SortStation {
  19. public:
  20.     double calculate(std::string& input);
  21.  
  22. private:
  23.     std::stack<char> container;
  24. };
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement