Requirement: Have a large TXT file (1,000,000 data), read the useful database from TXT and save to Oracle databaseUsing Java implementations:1. Read the file2. Insert the database into the database after connection
1. Properties and IO Stream collection useThe collection here must be a Properties collection :public void load (Reader reader): reads the data from the file into the collectionpublic void Store (Writer writer,string comments): Storing data in a
Here are some of the lessons I summarized in the previous lesson and the code is most of the teacher's notes personally think is very good, but also a more classic content, sincere hope that these for those who want to learn some help!Because the
1. Description of the problem There are n lights, numbered 1-n. The first man turned the light on, and the second man pressedAll switches numbered in multiples of 2, the third person presses the switch of multiples of 3, and so on,A total of k
Here are some of the lessons I summarized in the previous lesson and the code is most of the teacher's notes personally think is very good, but also a more classic content, sincere hope that these for those who want to learn some help!Because the
If you often need to modify a string, such as inserting, deleting, stitching, and so on, it is more appropriate to use Sringbuffer, because stringbuffer in string processing is not to generate new objects in memory because of the string class.The
Packagecom.trs.utils; Public classKmpstr {/** In the KMP algorithm, the most difficult to find is the next function, how to understand the next function is a problem, especially k=next[k], here * need to point out that when P[i]!=p[j], we only by
One or three major categories1, Channels2, selector and Selectionkey3. Buffer and its sub-categoriesNote: All channel needs to be used in conjunction with the buffer class to implement buffers through the buffer classThe synchronous non-blocking
Features of the Java language√ Simplicity √ Object-oriented √ distributed √ robustness √ cross-platform √ high performance √ multithreading capability √ Dynamic √ securityJava cross-platform mechanism: the Java language Cross-platform, is
In recent days, the Java programming idea turned over, suddenly found that the so-called XXX from the beginning to the mastery of the series to speak simply can not see, can only be used as an introductory book.In order to not forget in the future,
Only the sort of the int type is considered, and the generic implementation is considered later.1 Public classHeap {2 3 Public intHeap_size;//initialized in Build_max_heap, automatically called by Heap_sort4 5 Public intParentinti)
Code: Packagecom.huey.dream.utils;ImportJava.util.regex.Matcher;ImportJava.util.regex.Pattern; Public classStringUtils {StaticString Cn_regex = "[\u4e00-\u9fa5]";//Regular expressions that match Chinese characters StaticPattern Cn_pattern
I have recently looked at the Java programming idea. Some gains. This book is really good.Initialization in Java is a belief that many people know. However, the specific initialization steps are not necessarily initialized several times. On the Code
Staticis static modifier, what is static modifier? As you know, any variable or code in the program is automatically allocated by the system at compile time to store the memory, and so-called static refers to the memory allocated after compilation
Java BASICS (4): java Basics
Here are some of the knowledge points and code I summarized in my previous class. Most of the notes I think are very good and classic, sincerely hope that these will help those who want to learn!
It is inconvenient to
Efficiency of writing java IO files-comparison of several methods, javaio
Various writing methods
/*** 1 Write FileOutputStream by byte** @ Param count Number of Write cycles* @ Param str write a string*/Public void outputStreamTest (int count,
Java Web cookie Validity PeriodCookie validity period in Java Web (1) adding cookie emailCook = new Cookie (name2, "whuang") in Java Web Background; emailCook. setPath ("/"); response. addCookie (emailCook); (2) if the validity period is not
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.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service