原创 Codeforce 723A - The New Year: Meeting Friends

Description There are three friend living on the straight line Ox in Lineland. The first friend lives at the point x

原创 POJ 3041 - Asteroids

Description Bessie wants to navigate her spaceship through a dangerous asteroid field in the shape of an N x N grid (1

原创 NYOJ 99 - 單詞拼接

描述 給你一些單詞,請你判斷能否把它們首尾串起來串成一串。 前一個單詞的結尾應該與下一個單詞的道字母相同。 如 aloha dog arachnid gopher tiger rat 可以拼接成:aloha.arachnid.dog.go

原创 HDU 1427 - 速算24點

Problem Description 速算24點相信絕大多數人都玩過。就是隨機給你四張牌,包括A(1),2,3,4,5,6,7,8,9,10,J(11),Q(12),K(13)。要求只用'+','-','*','/'運算符以及括號改變運

原创 Address Of A Gif

點贊 收藏 分享 文章舉報 Sureina 發佈了158 篇原創文章 · 獲贊 23 · 訪問量 6萬+ 私信 關注

原创 UVA 11426 - GCD Extreme(II)

題意:求sum(gcd(i,j),1<=i<j<=n) 1 < n <= 40000000 1.建立遞推關係,s(n)=s(n-1)+gcd(1,n)+gcd(2,n)+……+gcd(n-1,n); 2.設f(n)=gcd(1,n)+g

原创 JSP的Struts2框架實現數據庫連接的登錄驗證界面

框架這東西剛開始看真的是一臉懵逼,用struts2做了一個簡單的登錄小功能,現在對於框架已經是十分明朗了。【全文借鑑於:Struts2+MySql,又更改爲連接SqlServer數據庫】在Eclipse上開發的Dynamic Web Pr

原创 PAT L1-006 連續因子

L1-006. 連續因子 時間限制 400 ms 內存限制 65536 kB 代碼長度限制 8000 B 判題程序 Standard 作者 陳越 一個正整數N的因子中可能存在若干連續的數字。例如630可以

原创 實驗報告 二叉樹

一、二叉樹的遍歷 #include <stdio.h> #include <stdlib.h> #include <malloc.h> #define MAX 20 #define OK 1 #define ERROR 0 #define

原创 HDU 5734 - Acperience

Problem DescriptionDeep neural networks (DNN) have shown significant improvements in several application domains includ

原创 HDU 5724 - Chess

Problem DescriptionAlice and Bob are playing a special chess game on an n × 20 chessboard. There are several chesses on

原创 NYOJ 68 - 三點順序

描述 現在給你不共線的三個點A,B,C的座標,它們一定能組成一個三角形,現在讓你判斷A,B,C是順時針給出的還是逆時針給出的? 如: 圖1:順時針給出 圖2:逆時針給出 <圖1> <圖2>輸入 每行是一組測試數據,有6個整數x1,y1

原创 HDU 5914 - Triangle

Problem DescriptionMr. Frog has n sticks, whose lengths are 1,2, 3⋯n respectively. Wallice is a bad man, so he does not

原创 HDU 5727 - Necklace

Problem Description SJX has 2*N magic gems. N of them have Yin energy inside while others have Yang energy. SJX wants t

原创 PAT L1 - 020 帥到沒朋友

當芸芸衆生忙着在朋友圈中發照片的時候,總有一些人因爲太帥而沒有朋友。本題就要求你找出那些帥到沒有朋友的人。輸入格式: 輸入第一行給出一個正整數N(<=100),是已知朋友圈的個數;隨後N行,每行首先給出一個正整數K(<=1000),爲朋