From 74379325f916dc8c940382f3d7e6fa9b36435b4c Mon Sep 17 00:00:00 2001 From: Kirito <1362050620@qq.com> Date: Wed, 9 Nov 2016 13:03:16 +0800 Subject: [PATCH] Create 1883.cpp --- QUSTOJ/1883.cpp | 45 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) create mode 100644 QUSTOJ/1883.cpp diff --git a/QUSTOJ/1883.cpp b/QUSTOJ/1883.cpp new file mode 100644 index 0000000..a746de4 --- /dev/null +++ b/QUSTOJ/1883.cpp @@ -0,0 +1,45 @@ +#include +#include +#include +using namespace std; +struct pack +{ + string man,woman; +}; +int main() +{ + int n; + cin>>n; + queue manbus; + queue womanbus; + string name,sexual; + while(n--) + { + cin>>name>>sexual; + if(sexual=="M") + { + manbus.push(name); + } + else + { + womanbus.push(name); + } + } + cout<<"The dancing partners are:"<