hihoCoder太阁最新面经算法竞赛10 register

Ended

Participants:138

Verdict:Accepted
Score:100 / 100
Submitted:2016-07-24 12:40:53

Lang:G++

Edit
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
#include <iostream> 
#include <string.h>
#include <math.h>
#include <stdio.h>
#include <string>
#include <iostream>
#include <algorithm>
using namespace std;
const int MAX=100;
int bitcnt[1<<11];
void output(int s)
{
    int i,p=1;
    int mm=0,hh=0;
    for(i=0;i<6;i++)
    {
        mm+=(s&1)*p;
        s>>=1;
        p<<=1;
    }
    p=1;
    for(i=0;i<5;i++)
    {
        hh+=(s&1)*p;
        s>>=1;
        p<<=1;
    }
    if(0<=hh&&hh<=23&&0<=mm&&mm<=59)
    {
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX