Archive | Programming

Calculate the sum of the numbers from 1 to 100

Threads: Calculate the sum of the numbers from 1 to 100 Hello everyone, if the total 2 numbers a and b, it is quite simply the then, however, to calculate the total number of consecutive multiple threads all we like how? We found that the nature of the numbers 1 to 100 is continuous so we can use loops to perform […]

Superlative solving equations ax + b = 0

Threads: Superlative solving equations ax + b = 0 (other a 0) With the coefficients a, b is entered from the keyboard. To solve this, you recall the mathematical knowledge we have learned of the ordinary. Due to a different 0 so we always have x = -b experimental / a. So easy and, formula has, only now just code. Simple […]

[Pascal – TUT] Posts 10: Files in pascal – File Type

1 The concept of file: The file is a sequence of elements of the same type are arranged sequentially. The data files are stored in external memory under a certain name. File aggregation in it some element of data has the same structure but different array like array element number of the file is not defined. [qads] In Pascal 3 file types […]

[Pascal – TUT] – Posts 11 : Pointers in Pascal

Since posting the order a bit of confusion to all 10: Files in pascal - file type was written earlier, you see here nhé. During the work we often have to work with the long list and of course we will consider using the array immediately. However, the use of the array is not always, with the long list […]

Find the largest number of 3 number

Hello everyone, surely you know how to find the greatest among 2 numbers a and b. We only have to compare a to b, larger number, then take it alone. But with 3 of a, b, c then why? Threads: Enter 3 integer a, b, c from the keyboard, Please print out the largest number of 3 which. Simple way that you can […]

League quadratic equation 2 ax² + bx + c = 0

Hello everyone, at all before we solve it most, this article we are going to solve the equation Career 2 nhé. Threads: League quadratic equation 2: ax² + bx + c = 0 (a ≠ 0) with a, b, c input from the keyboard We recall knowledge of the quadratic equation 2 with a ≠ 0 as follows: B1: calculate delta: D = […]

[C / C ] Getting mouse events in C on Ubuntu – Mouse event C on Ubuntu

To capture mouse events in ubuntu we use the library X11 / Xlib.h. Install this library with the command: sudo apt-get install libx11-dev This is an illustration from the program page http://stackoverflow.com/questions/14553435/how-to-listen-for-mouse-events-in-linux However, I still do not know how to use it in graphics. We hope you share on this issue. Refer: Click in Dev-C

[JavaSwing] JPanel

Content and Layout Order Create JPanel Border After the opening introduction to the JFrame and the introduction of JLabel, JButton and JTextField perhaps you have become familiar with how to create an interface in Java Swing. Prior to the introduction of frequently used objects, I think we should learn a very important it is to Container (container, holder) and […]

[Java] Game chess caro 2 players

Today, I continue to share your Game caro 2 players with nice graphical interface, friendly and easy to use. The program allows the player can choose a new game, new game, please go back and lost. On each side of the image that shows the match score and the state to turn someone away. When starting the game allows you to choose […]

[Java] Program Calculator – Palmtops

Today I will introduce and share with your Pocket PC program (Calculator) written in java-based 2 transfer algorithm infix expression to postfix and calculate the value of the expression suffix. This program is an upgrade to the version on android I did some time ago. The interface of the program is relatively simple, with 3 […]