A simple introduction to digital DP

Time is not enough. Previously, I was misunderstood by the search code, thinking that the digital DP is actually a memory search. (Although the search is really comfortable and good to think) But later it was discovered that the standard format of digital DP is in fact preprocessing + DP…   Introduction of digital DP The digital DP is actually the number of numbers that you deal with in an interval that satisfies the conditions, but in general the interval is desperately large… For example, 1e9 is conscience. The general rule is 1e18 or even 1e10.n (n Usually 3 or 5 times.   G...

Object oriented three, constraint, encryption

One, constraint (similar to java interface py has no interface) Artificial constraints class BaseMessage(object): def send(self,x1): """ You must inherit BaseMessage, and then you must write the send method. Used to complete specific business logic.""" raise NotImplementedError(".send() It must be rewritten.") class Email(BaseMessage): def send(self,x1): """ You must inherit BaseMessage, and then you must write the send method. Used to complete specific business logic.""" print('Send mail') obj = Email() obj.send(1) Abstract class a...

Ubuntu16.04 configuration static IP (NAT mode) under VM virtual machine

Recently, in the process of writing a project on vm, you need to connect mysql on the virtual machine through Navicat on windows. it is found that the Ubuntu 16.04 system IP under the virtual machine is different every time you restart the virtual machine, resulting in the original Navicat configured connection can not be made.Use. So think of the need to configure a system in the VM will not change the ip, through the Internet to find relevant information, and according to their own practice, now will sort out the notes. You can configure static IP for VM virtual machines in a handover manne...

Converting strings to integers

Title Description Converting a string to an integer (which implements the Integer. valueOf (string) function, but returns 0 if the string does not meet the number requirement) requires that the library function that converts an integer using a string cannot be used. The value is 0 or the string is not a valid number.The value is returned to 0. Examples input +2147483647 1a33 output 2147483647 0 Title Description This is a headache because the topic requires no library function. Then Baidu said it could convert strings into ASCII codes (decimal values). The conversion function i...

IOS adds the completion button for the numeric keypad.

When entering the price, the keyboard that pops out can only have digits and decimal points. The pop-up keyboard doesn’t have the completion key. You can click exit if you want to exit the keyboard, but for a better user experience, add a UI Toolbar to the keyboard.   Set ToolBar: - (UIToolbar *)addToolbar { UIToolbar *toolbar = [[UIToolbar alloc] initWithFrame:CGRectMake(0, 0, CGRectGetWidth(self.view.frame), 30)]; toolbar.tintColor = [UIColor blackColor]; toolbar.backgroundColor = [UIColor lightGrayColor]; UIBarButtonItem *prevItem = [[UIBarButtonItem alloc] initWit...

Fuda soft worker 1816. First homework preparation

Part 1. simple self introduction” 031602208;I am Chen Yu; my hobby is beer and skittles; my favorite is baking gluten (Bauhinia first floor); don’t hang up. (6) It is said that the dropout rate of software engineering practice is very high. Did you know about this course before the course selection? Why did you choose this course? If your teammates are halfway backWhat will you do? Answer: I don’t know. It was for the credits. Teammates quit classes and decide whether to go on alone or to cooperate with others depending on the difficulty of completing the task.