#include<iostream> #include<stdio.h> #include<algorithm> #include<string.h> #include<string> #include<vector> #include<queue> using namespace std; typedef long long LL; struct node{ int c; int tn; int tm; int num; node(int a,int b,int dd,int d) { c =...