Video tutorial on changing the magic ruler from 24 to 2014 (upgraded version)
I uploaded a video tutorial on changing the magic ruler ball on Youku.
Internet thinking: iterative thinking, extreme thinking.
Today, we have recorded and uploaded an upgraded video tutorial for the 24-segment magic ruler ball change.
This upgrade mainly includes the following chan
① first, the ruler is not visible by default, and to display the ruler, we can move the mouse to the top of the page, and the ruler will be displayed in a few seconds.
② How do you make it show all the time? Click the rightmost button on the ruler to make it appear all the time.
③
O (n) to enumerate all segments with a length of K, each violent transfer.
During the transfer, only one number is inserted from the end and one number is deleted from the front.
Calculate the current Max and Min values.
These operations are O (logn) with the Multiset (distinct element is rewritable.
1 #include
[Ruler acquisition method] [Multiset] bzoj1342 [baltic2007] sound mute Problem
Test instructionsIn a sequence of length n, find the shortest length sequence so that it is greater than or equal to s;Ideas:pointer, water problem;AC Code:#include /*#include */using namespacestd;#definefor (i,j,n) for (int i=j;i#defineRiep (n) for (int i=1;i#defineRIOP (n) for (int i=0;i#defineRJEP (n) for (int j=1;j#defineRJOP (n) for (int j=0;j#defineMST (SS,B) memset (ss,b,sizeof (ss));typedefLong Longll;templateclassT>voidRead (tnum) { CharCH;BOOLf=false; for(Ch=getchar (); ch'0'|| Ch>
A Bit FunTime limit:5000/2500 MS (java/others) Memory limit:32768/32768 K (java/others)Problem descriptionthere is n numbers in a array, as A0, A1 ..., an-1, and another number M. We define a function f (i, j) = ai|ai+1|ai+2| ... | Aj. Where "|" is the bit-or operation. (I The problem is really simple:please count the number of the different pairs of (I, J) where F (i, J) Inputthe first line has a number T (T For each test case, first line contains, numbers n and M. (1 Outputfor every case, you
Title Link: Http://codeforces.com/problemset/problem/660/CRuler, each time you encounter 0 of the time to fill a 1, until the completion or out of bounds. Each time a 0 point is recycled from left to right. The recording path is jammed with two pointers, each updated.1#include 2#include 3#include 4#include 5#include 6#include 7#include 8#include 9#include Ten#include One#include A#include -#include -#include the#include -#include Set> -#include -#include + - using namespacestd; + A Con
POJ3320 Jessica ' s Reading problemSet is used to count the number of all non-repeating knowledge points, and map is used to maintain the number of occurrences of each knowledge point on the interval [s,t], which is a good representation of the flexible application of map #include #include#include#include#include#include#include#includeSet>#includestring>#includeusing namespacestd;Const intINF =0x3f3f3f3f; typedefLong Longll;Const intMax_p =1000010;intP;inta[max_p];intMain () {scanf ("%d", q);
A-Fried chicken want to lose weight of stringTime limit:MS Memory Limit:65535KB 64bit IO Format:SubmitStatusPracticenbut 1576DescriptionOnce upon a time, there was a string of long, long strings consisting of n lowercase letters.One day when it was looking in the mirror, he felt too fat, so he wanted to lose weight. When you lose weight, you can constantly remove the first or last character.After it wants to lose weight, for a slim factor m, the slim factor must contain ' a ', ' B ', ' C ' ...
Title: http://poj.org/problem?id=3320Test instructions: Given an array of n elements, find the shortest interval so that the element type within the interval equals the element type of the entire array.Analysis: The beginning of the violent enumeration interval x, and then find the smallest y, so that the interval [x, y] satisfies the condition, X shifted to the X ', now Y ' certainly not on the left of Y. Both map and hash can be used.Map Code:#include Hash code:#include POJ 3320 Jessica ' s Re
Poj3320 (ruler acquisition) and poj3320
N number. The minimum interval overwrites all the different numbers in n number.
Solution:
AC code:
Import java. util. hashMap; import java. util. hashSet; import java. util. map; import java. util. imports; import java. util. set; public class Main {/*** @ param args */static int n; static Set
Jessica‘s text-book. The second line contains P non-negative integers describing what idea each page is about. The first integer is what the first page is about, the second integer is what the second page is about, and so on. You may assume all integers that appear can fit well in the signed 32-bit integer type.
Output
Output one line: the number of pages of the shortest contiguous part of the book which contains all ideals covered in the book.
Sample Input
51 8 8 8 1
Sample output
2
AC cod
Subsequence
Time Limit: 1000MS
Memory Limit: 65536K
Total Submissions: 9050
Accepted: 3604
DescriptionA sequence of n positive integers (InputThe first line is the number of test cases. The program have to read the numbers N and S, separated by a interval, from the first line. The numbers of the sequence is given in the second line of the "test case", separated by intervals. The input would finish with the end of file.OutputThe the
A series integer a0,a1......an-1 and integer s with a given length of N. The minimum value of the length of a continuous sub-sequence with a sum not less than S is calculated. If the solution does not exist, the output is 0.Input n=10S=15a=[5,1,3,5,10,7,4,9,2,8]Output2 [5,10]functionsolve () {varRes=n+1; varS=0,t=0,sum=0; for(;;) { while(tS) {Sum+=a[t++]; } if(Sum Break} res=math.min (res,t-s); Sum-=a[s++]; } if(res>N) { //solution does not existRes=0; } returnRes;}Do the f
When you open the Word window, you will see a row of rulers above the window, followed by 2, 4, 6 ... 38, it is in the character unit, in the song body fifth Word format, each row can enter about 38 Chinese characters. But sometimes it is not convenient to use, especially in the tabulation, drawing, it is not intuitive, at this time, we can modify the ruler in centimeters.
Click the tools → options command, and in the Options dialog box that pops up,
Problem descriptionHave a10\leq10≤ length\leq 1,000,000≤1,000,00 0strings, consisting only of lowercase letters. How many substrings are available, containing at least K (1 \leq k \leq)K(1≤k≤26) different letters? Enter a descriptionThe input contains multiple sets of data. The first line has an integert (1\leq t\leq) t (1≤t≤1ss. The second line enters an integer kk. Output descriptionFor each set of data, the output meets the required number of substrings.Input sample2abcabcabca4abcabcabcabc3
How do PS ruler units change to pixels?
1, first find our desktop PS icon, double-click to open our options
2, find the file-new-Create a new blank canvas,
3, we find the view to find the ruler, shortcut key is Ctrl+r, we will immediately show us the ruler
4, show us the ruler,
to change the ruler unit of measure, follow these steps:
Step one: Click on the "File" button.
Step two: Click "Options" in the menu list on the left.
Step three: On the left side of the Word Options dialog box that pops up, click the "Advanced" tab.
Step four: Scroll down to the show section. Select an option from the unit of Measure Drop-down list.
Step five: Depending on your selection
BarTender2016 Ruler unit of measure set method one:
By default, the unit of measure for bartender 2016 is matched according to the system. If you use the Chinese version of the operating system, its default unit of measure is millimeters.
You can modify the bartender label unit of measure in two ways:
1, by changing the bartender document options;
Click View > View options in the menu bar to open the Bartender
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.