<commit_before>#include <cmath>
#include <cstdio>
#include <vector>
#include <iostream>
#include <algorithm>
#include <stack>
#include <queue>
using namespace std;

class MyQueue {

    public:
        stack<int> stack_newest_on_top, stack_oldest_on_top;
        void push(int x) {
            stack_newest_on_top.push(x);

            stack<int> temp = stack_newest_on_top;

            while (!stack_oldest_on_top.empty()) {
                stack_oldest_on_top.pop();
            }

            while (!temp.empty()) {
                stack_oldest_on_top.push(temp.top());
                temp.pop();
            }
        }

        void pop() {
            stack_oldest_on_top.pop();

            stack<int> temp = stack_oldest_on_top;

            while (!stack_newest_on_top.empty()) {
                stack_newest_on_top.pop();
            }

            while (!temp.empty()) {
                stack_newest_on_top.push(temp.top());
                temp.pop();
            }
        }

        int front() {
            return stack_oldest_on_top.top();
        }
};

int main() {
    MyQueue q1;
    int q, type, x;
    cin >> q;

    for(int i = 0; i < q; i++) {
        cin >> type;<commit_msg>[HACKERRANK] Queues: A Tale of Two Stacks V2<commit_after>#include <cmath>
#include <cstdio>
#include <vector>
#include <iostream>
#include <algorithm>
#include <stack>
#include <queue>
using namespace std;

class MyQueue {

    public:
        stack<int> stack_newest_on_top, stack_oldest_on_top;
        int popCount;

        MyQueue() {
            popCount = 0;
        };

        void push(int x) {
            stack_newest_on_top.push(x);
        }

        void pop() {
            popCount++;
        }

        int front() {
            stack<int> temp = stack_newest_on_top;

            while (temp.size() - popCount > 1) {
                temp.pop();
            }

            return temp.top();
        }
};

int main() {
    MyQueue q1;
    int q, type, x;
    cin >> q;

    for(int i = 0; i < q; i++) {
        cin >> type;
{'fraction_non_alphanumeric': 0.12463343108504399, 'fraction_numerical': 0.003421309872922776, 'mean_word_length': 1.6412903225806452, 'pattern_counts': {'":': 0, '<': 24, '<?xml version=': 0, '>': 31, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5210777', 'n_tokens_mistral': 695, 'n_tokens_neox': 660, 'n_words': 143}