Selasa, 31 Januari 2017

How to return objects in Function C++ programming

We can not only pass objects as function arguments but can also return objects from functions. We can return an object in the following three ways: Returning by value which makes a duplicate copy of the local object. Returning by using a reference to the object. In this way the address of the object is passed implicitly to the calling function. Returning by using the ‘this pointer’ which explicitly sends the address of the object to the calling function.   Following program demonstrates the three ways of returning objects from a function: 1 2 3 4 5 6 7 8

The post How to return objects in Function C++ programming appeared first on Coding Security.


How to return objects in Function C++ programming
read more

What is the terminology of Functions in C programming

Until now, in all the C programs that we have written, the program consists of a main function and inside that we are writing the logic of the program. The disadvantage of this method is, if the logic/code in the main function becomes huge or complex, it will become difficult to debug the program or test the program or maintain the program. So, generally while writing the programs, the entire logic is divided into smaller parts and each part is treated as a function. This type of approach for solving the given problems is known as Top Down approach. The

The post What is the terminology of Functions in C programming appeared first on Coding Security.


What is the terminology of Functions in C programming
read more

Senin, 30 Januari 2017

An introduction to HTTP protocol in web

All web communications use the same protocol HTTP. Latest version of HTTP is 1.1 released in 1999. A HTTP communication consists of two phases: a request (from client to server) and a response (from server to client). In both the request and response phases, the unit of communication contains two parts: one is the header and the other is the body part. The format for a HTTP request is shown below: HTTP-request-method  Resource-path  HTTP-version Header fields Blank line Body of the request According to HTTP 1.1 there are several request methods, among which some important methods are listed below: Among

The post An introduction to HTTP protocol in web appeared first on Coding Security.


An introduction to HTTP protocol in web
read more

How to use variables in Interfaces (Java Programming)

An interface can contain constants (final variables). A class that implements an interface containing constants can use them as if they were declared in the class. Example demonstrating constants in an interface is given below: IArea.java (interface) 1 2 3 4 public interface IArea { double PI = 3.142; }   Driver.java (Main program which implements the above interface) 1 2 3 4 5 6 7 public class Driver implements IArea { public static void main(String args) { System.out.println(“PI value is: “ + PI); } } In the above code the class Driver.java implements the interface IArea and prints the value of the

The post How to use variables in Interfaces (Java Programming) appeared first on Coding Security.


How to use variables in Interfaces (Java Programming)
read more

How to work with built-in objects of String and Number in javascript

String object:  A string is a collection of characters. Most of the times in scripts, there is a need to work with strings. JavaScript provides various properties and methods to work with String objects. Whenever a String property or method is used on a string value, it will be coerced to a String object. One most frequently used property on String objects is length. The length property gives the number of characters in the given string. Consider the following example: var str = “Hello World”; var len = str.length;  The value stored in the len variable will be 11 which

The post How to work with built-in objects of String and Number in javascript appeared first on Coding Security.


How to work with built-in objects of String and Number in javascript
read more

Minggu, 29 Januari 2017

what are bit field classes in java

A field or member inside a class which allows programmers to save memory are known as bit fields. As we know a integer variable occupies 32 bits (on a 32-bit machine). If we only want to store two values like 0 and 1, only one bit is sufficient. Remaining 31-bits are wasted. In order to reduce such wastage of memory, we can use bit fields. Syntax of a bit field is as follows: type-specifier declarator: width;   In the above syntax declarator is an identifier (bit-field name), type-specifier is the data type of the declarator and width is the size

The post what are bit field classes in java appeared first on Coding Security.


what are bit field classes in java
read more

How to refer immediate super class constructor in java programming

Following are the uses of super keyword: To refer the immediate super class constructor To refer the immediate super class members   Refer super class constructor: The super keyword can be used to invoke the constructor of its immediate super class and pass data to it. Syntax for doing so is given below: super(parameters-list); When writing the above statement inside the constructor of the derived class, it must be the first line. It is a mandatory requirement. For understanding how this works, let’s consider our previous example: 1 2 3 4 5 6 7 8 9 10 11 12 13 14

The post How to refer immediate super class constructor in java programming appeared first on Coding Security.


How to refer immediate super class constructor in java programming
read more

What is the correct use case of the Method overriding in java

Method overriding is possible only when the following things are satisfied: A class inherits from another class (inheritance). Both super class and sub class should contain a method with same signature. Note: Method overriding does not depend up on the return type of the method and the access specifiers like (public, private, protected etc..). What is the difference between method overloading and method overriding? Both may look similar but they are quite different in the following ways: Method overloading takes place when a class contains multiple methods with the same name but varying number of parameters or types of parameters.

The post What is the correct use case of the Method overriding in java appeared first on Coding Security.


What is the correct use case of the Method overriding in java
read more

Sabtu, 28 Januari 2017

What are the associativity rules to be followed in the Expressions

When an expression contains operators from the same group, associativity rules are applied to determine which operation should be performed first. The associativity rules of Java are shown below: Now, let’s consider the following expression: 10-6+2 In the above expression, the operators + and – both belong to the same group in the operator precedence chart. So, we have to check the associativity rules for evaluating the above expression. Associativity rule for + and – group is left-to-right i.e, evaluate the expression from left to right. So, 10-6 is evaluated to 4 and then 4+2 is evaluated to 6.   Use

The post What are the associativity rules to be followed in the Expressions appeared first on Coding Security.


What are the associativity rules to be followed in the Expressions
read more

What is class loader heap in Java Virtual Machine

A class loader implementation is a program that should be able to perform the following activities: Loading: finds and imports the binary data for a type Linking: performs verification, preparation, and resolution (optional) Initialization: Invokes Java code that initializes class variables to their proper initial values   Heap The heap area of JVM is used for dynamic memory allocation. In HotSpot the heap is divided into generations: The young generation stores objects whose lifetime is short. The old generation stores objects which persist for longer durations. The permanent generation area stores class definitions and other metadata. This area is removed

The post What is class loader heap in Java Virtual Machine appeared first on Coding Security.


What is class loader heap in Java Virtual Machine
read more

Why do we need method overloading in Java

In Java, overloading provides the ability to define two or more methods with the same name. What is the use of that? For example, you want to define two methods, in which, one method adds two integers and the second method adds two floating point numbers. If there is no overloading, we have to create two different methods. One for adding two integers and the other for adding two floating point numbers. As the underlying purpose of the methods is same, why create methods with different name? Instead of creating two different methods, overloading allows us to define two methods

The post Why do we need method overloading in Java appeared first on Coding Security.


Why do we need method overloading in Java
read more

Jumat, 27 Januari 2017

What is the correct requirement to invoke Finally in Exception handling

The throws keyword can be used in method definition to let the caller of a method know about the exceptions that the method might raise and which are not handled by that method. The general form of throws is as follows: type method-name(parameters-list) throws exception-list { //body of method } The exception-list is a comma separated list of exceptions that the method might throw. Except the sub classes of Error and RuntimeException classes all other exceptions (checked exceptions) must be mentioned explicitly with the throws keyword. Otherwise, it will lead to compile-time errors. Let’s see a sample program which demonstrates the use of throws keyword: 1 2 3 4 5 6

The post What is the correct requirement to invoke Finally in Exception handling appeared first on Coding Security.


What is the correct requirement to invoke Finally in Exception handling
read more

What are the methods of Object Class in Java Programming

Following are different methods provided by the Object class: clone() method This method is used to create a new object which is same as the object being cloned. Syntax of this method is as follows: Object clone() equals() method This method is used to determine whether one object is same as the other object. Syntax of this method is as follows: boolean equals(Object obj) finalize() method This method is used to write resource clean up code when the object is just to be garbage collected. Syntax of this method is as follows: void finalize() getClass() method This method is used to

The post What are the methods of Object Class in Java Programming appeared first on Coding Security.


What are the methods of Object Class in Java Programming
read more

Why do we need synchronization in Java Programming

When two or more threads are accessing the same resource like a variable or a data structure, it may lead to inconsistent data or values. Such conditions that lead to inconsistency are known as race conditions.   As an example let’s consider a variable count whose value is 7 at present. Consider two operations: count = count + 1 which is executed by thread1 and another operation count = count – 1 which is executed by thread2. Note that both threads are sharing the common variable count.   If both threads execute in parallel then the sequence of operations can be either: count = count +

The post Why do we need synchronization in Java Programming appeared first on Coding Security.


Why do we need synchronization in Java Programming
read more

Kamis, 26 Januari 2017

How to make a pointer direct to derived class in C++ Programming

A base class pointer can point to a derived class object. But, a derived class pointer can never point to a base class object. Following program demonstrates object slicing using a base class pointer: One of the main advantages of object oriented programming is reusability. Using already existing code is known as reusability. C++ supports reusability through inheritance which is creating a new class from already existing class.   Inheritance is defined as deriving properties and behavior from one class to another class. The existing class from which properties and behavior are derived is known as a base class or

The post How to make a pointer direct to derived class in C++ Programming appeared first on Coding Security.


How to make a pointer direct to derived class in C++ Programming
read more

How to use Maps Data Structure in Generic C++ Programming

A map is like an associative array where each element is made of a pair. A pair contains a key and a value. Key serves as an index. The entries in a map are automatically sorted based on key when data is entered. Map container provides the following functions: Following program demonstrates working with a map: Data is stored in a linear fashion. Each element is related to other elements by its position. Elements can be accessed using an iterator. Examples of sequence containers are: Vector, List, and Dequeue.   Vector: Dynamic array that allows insertion and deletion of elements

The post How to use Maps Data Structure in Generic C++ Programming appeared first on Coding Security.


How to use Maps Data Structure in Generic C++ Programming
read more

How to make HTML dynamic using JavaScript

JavaScript code is executed within the web pages. So, your web page contains not only HTML tags but also statements (scripts) written using a scripting language like JavaScript. There are two ways to include JavaScript in our web pages. One way is to include the JavaScript statements inside <script> and </script> tags. Below is the syntax for including JavaScript in <script> tags: 1 2 3 <script type=“text/javascript”>     JavaScript code… </script> In the above code, the attribute type is used to specify which scripting language we are using to write the statements embedded within the <script> tags. There are many scripting languages

The post How to make HTML dynamic using JavaScript appeared first on Coding Security.


How to make HTML dynamic using JavaScript
read more

Rabu, 25 Januari 2017

How to overload new and delete operators in C++ Programming

C++ allows programmers to overload new and delete operators due to following reasons: To add more functionality when allocating or deallocating memory. To allow users to debug the program and keep track of memory allocation and deallocation in their programs.   Syntax for overloading new operator is as follows: void* operator new(size_t size);   Parameter size specifies the size of memory to be allocated whose data type is size_t. It returns a pointer to the memory allocated.   Syntax for overloading delete operator is as follows: void operator delete(void*);   The function receives a parameter of type void* and returns

The post How to overload new and delete operators in C++ Programming appeared first on Coding Security.


How to overload new and delete operators in C++ Programming
read more

An introduction to Generic Programming

To generate short, simple code and to avoid duplication of code, C++ provides templates to define the same piece of code for multiple data types. With templates, programmers can define a family of functions or classes that can perform operations on different types of data.   Templates comes under the category of meta-programming and auto code generation, where the generated code is not visible in general. Through templates, C++ supports generic programming.   Generic programming is a type of programming where the programmer specifies a general code first. That code is instantiated based on the type of parameters that are

The post An introduction to Generic Programming appeared first on Coding Security.


An introduction to Generic Programming
read more

How to work with vectors in C++ Programming

A vector is like a dynamic array where all the elements are stored contiguously. Elements can be added or removed at run-time as and when needed. Vector provides the following functions for working with the data stored in it: Following program demonstrates working with a vector: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 #include<iostream> #include<vector> using namespace

The post How to work with vectors in C++ Programming appeared first on Coding Security.


How to work with vectors in C++ Programming
read more

Selasa, 24 Januari 2017

What are the volatile Objects and Member functions in C++ Programming

An object which can be modified by some unknown forces (like hardware) other than the program itself can be declared as volatile. Compiler doesn’t apply any optimizations for such volatile objects. Syntax for declaring an volatile object is as follows: volatile ClassName object-name;   A member function can be declared as volatile to make the access to member variables to be volatile. A volatile object can access only volatile functions. Syntax for creating a volatile function is as follows: return-type function-name(params-list) volatile;   Following program demonstrates both volatile objects and volatile programs: 1 2 3 4 5 6 7 8

The post What are the volatile Objects and Member functions in C++ Programming appeared first on Coding Security.


What are the volatile Objects and Member functions in C++ Programming
read more

How to return objects in C++ Programming functions

We can not only pass objects as function arguments but can also return objects from functions. We can return an object in the following three ways: Returning by value which makes a duplicate copy of the local object. Returning by using a reference to the object. In this way the address of the object is passed implicitly to the calling function. Returning by using the ‘this pointer’ which explicitly sends the address of the object to the calling function.   Following program demonstrates the three ways of returning objects from a function: 1 2 3 4 5 6 7 8

The post How to return objects in C++ Programming functions appeared first on Coding Security.


How to return objects in C++ Programming functions
read more

How to work with manipulators in C++ Programming

Manipulators are helper functions which can be used for formatting input and output data. The ios class and iomanip.h header file has several pre-defined manipulators.   Below table lists out several pre-defined manipulators. The manipulators hex, oct, dec, ws, endl, and flush are defined in iostream.h. The manipulators setbase(), width(), fill(), etc., that require an argument are defined in iomanip.h. User-Defined Manipulators   Sometimes, to satisfy custom requirements, we have to create our own manipulator. Such manipulators which are created by the programmer or user are known as user-defined manipulators.   Syntax for creating a user-defined manipulator is as follows:

The post How to work with manipulators in C++ Programming appeared first on Coding Security.


How to work with manipulators in C++ Programming
read more

Senin, 23 Januari 2017

What is the servlet config interface in java programming

The ServletConfig interface provides a standard abstraction for the servlet object to get environment details from the servlet container. Container implementing the ServletConfig object supports the following operations: Retrieve the initialization parameters from xml file. Retrieve the ServletContext object that describes the application’s runtime environment. Retrieve the servlet name as configured in xml.   HttpServletRequest Interface   The HttpServletRequest interface is a subtype of ServletRequest interface. Implementation for this interface is provided by the servlet container. The HttpServletRequest interface object allows us to access the data available in the HTTP headers and HTTP requests. Following methods helps us to access

The post What is the servlet config interface in java programming appeared first on Coding Security.


What is the servlet config interface in java programming
read more

What are swing controls in Java Programming

In this article we will look at some of the swing controls available in javax.swing package along with sample Java code for each control.   Labels The JLabel class is used to display a label i.e., static text. A JLabel object can be created using any one of the following constructors: JLabel(Icon icon) JLabel(String str) JLabel(String str, Icon icon, int align) In the above constructors icon is used to specify an image to be displayed as a label. Icon is a predefined interface which is implemented by the ImageIcon class. str is used to specify the text to be displayed in the label and align

The post What are swing controls in Java Programming appeared first on Coding Security.


What are swing controls in Java Programming
read more

How to handle error while performing I/O operations

While writing programs which involve accessing files, certain errors might occur while performing I/O operations on a file. Some of the error situations include the following: Trying to read beyond the end-of-file mark. Device overflow. Trying to use a file that has not been opened. Trying to perform an operation on a file, when the file is being use by another application. Opening a file with invalid name. Attempting to write to write-protected file. If such errors are unchecked, it may lead to abnormal termination of the program or may lead to incorrect output. C library provides two functions namely

The post How to handle error while performing I/O operations appeared first on Coding Security.


How to handle error while performing I/O operations
read more

Minggu, 22 Januari 2017

Symfony vs Laravel which is the best PHP framework

In computer programming, a software framework is an abstraction in which software providing generic functionality can be selectively changed by additional user-written code, thus providing application-specific software. A software framework is a universal, reusable software environment that provides particular functionality as part of a larger software platform to facilitate development of software applications, products and solutions. Software frameworks may include support programs, compilers, code libraries, tool sets, and application programming interfaces (APIs) that bring together all the different components to enable development of a project or system. Frameworks have key distinguishing features that separate them from normal libraries: inversion of

The post Symfony vs Laravel which is the best PHP framework appeared first on Coding Security.


Symfony vs Laravel which is the best PHP framework
read more

How to get started with Git (A source Control) for your app

Git is a free and open source distributed version control system designed to handle everything from small to very large projects with speed and efficiency. Git is easy to learn and has a tiny footprint with lightning fast performance. It outclasses SCM tools like Subversion, CVS, Perforce, and ClearCase with features like cheap local branching, convenient staging areas, and multiple workflows. 1. Installing Git For downloading git installer, you can visit Git official website. and install it to your system. 2. Creating a Git Repository So now you are done with the installation part. If so, you are ready to

The post How to get started with Git (A source Control) for your app appeared first on Coding Security.


How to get started with Git (A source Control) for your app
read more

What is the Difference between InnoDB and MyISLAM Engine

A database engine (or storage engine) is the underlying software component that a database management system (DBMS) uses to create, read, update and delete (CRUD) data from a database. Most database management systems include their own application programming interface (API) that allows the user to interact with their underlying engine without going through the user interface of the DBMS. 1. Referential Integrity Referential integrity ensures that relationship between tables remains consistent and strong. Or more specifically, this means when a table has a foreign key pointing to a different table in the same database . When any update or delete

The post What is the Difference between InnoDB and MyISLAM Engine appeared first on Coding Security.


What is the Difference between InnoDB and MyISLAM Engine
read more

Sabtu, 21 Januari 2017

How to work with ANSI preprocessor Directives

The ANSI committee has added some more preprocessor directives to the existing list. They are: #elif   Directive The #elif directive enables us to establish an “if…else…if” sequence for testing multiple conditions. The syntax is as shown below: 1 2 3 4 5 6 7 #if expr1 Stmts; #elif  expr2 Stmts; #elif  expr3 Stmts; #endif #pragma  Directive The #pragma directive is an implementation oriented directive that allows the user to specify various instructions to be given to the compiler. Syntax is as follows: 1 #pragma name Where name is the name of the pragma we want. For example, under Microsoft C, #pragma loop_opt(on)

The post How to work with ANSI preprocessor Directives appeared first on Coding Security.


How to work with ANSI preprocessor Directives
read more

What are Stringizing and Token Pasting Operators in C programming

  Stringizing Operator # ANSI C provides an operator # called stringizing operator to be used in the definition of macro functions. This operator converts a formal argument into a string. For example, if the macro is defined as follows: 1 #define     sum(xy)     printf(#xy  “ = %f \n”, xy) and somewhere in the program the statement is written as: sum(a+b); then the preprocessor converts this line as shown below: 1 printf(“a+b”  “ = %f \n”, a+b); Token Pasting Operator ## The token pasting operator ## defined by ANSI enables us to combine two tokens within a macro definition to form a single

The post What are Stringizing and Token Pasting Operators in C programming appeared first on Coding Security.


What are Stringizing and Token Pasting Operators in C programming
read more

How to work with File Inclusion Directives

The external files containing functions or macro definitions can be linked with our program so that there is no need to write the functions and macro definitions again. This can be achieved by using the #include directive. The syntax for this directive is as shown below:’ C provides many features like structures, unions and pointers. Another unique feature of the C language is the preprocessor. The C preprocessor provides several tools that are not present in other high-level languages. The programmer can use these tools to make his program easy to read, easy to modify, portable and more efficient. The

The post How to work with File Inclusion Directives appeared first on Coding Security.


How to work with File Inclusion Directives
read more

Jumat, 20 Januari 2017

Different ways to style the CSS document

There are different ways to specify style information for the HTML elements in a web page. Each method has its own advantages and disadvantages over the other methods. The different ways in which we can specify the style information are: Inline CSS Embedded CSS (Document Level CSS) Imported CSS External CSS Inline CSS In Inline CSS, the style information is specified inline i.e., within the HTML tag. We will use the style attribute of a HTML tag to specify the style information using Inline CSS. The syntax for Inline CSS is as shown below: <tagname  style=“property-name:value”>Content</tagname> An example for specifying

The post Different ways to style the CSS document appeared first on Coding Security.


Different ways to style the CSS document
read more

What is the use of inline functions in c++ programming

A normal function call would involve stack operations and processor to shift to the first instruction in the function definition which might take significant time. For small functions with one or two lines this time is unnecessary. Such functions can be declared as inline functions using the keyword inline.   In general, inline functions are faster than normal functions. When the compiler comes across a call to a inline function, it directly substitutes the function definition in the place of function which might increase the size of code. So, the use of inline keyword in programs should be minimal. Consider

The post What is the use of inline functions in c++ programming appeared first on Coding Security.


What is the use of inline functions in c++ programming
read more

What are built-in objects in javascript

To solve different kinds of problems, JavaScript provides various built-in objects. Each object contains properties and methods. Some of the built-in objects in Javascript are: Array Date Math String Number Array object:  The properties available on Array object are: Property Description length Returns the number of elements in the array constructor Returns the function that created the array object prototype Allows us to add properties and methods to an array object Methods available on Array object are: Method Description reverse() Reverses the array elements concat() Joins two or more arrays sort() Sort the elements of an array push() Appends one

The post What are built-in objects in javascript appeared first on Coding Security.


What are built-in objects in javascript
read more

Kamis, 19 Januari 2017

What are stream classes in C++ Programming

C++ provides several classes to work with stream based I/O. Such classes are known as stream classes and they are arranged in a hierarchy shown below: All these classes are declared in iostream.h header file. So, we have to include this header file in order to use the stream classes. As shown in the above figure, ios is the base class for all the stream classes from which istream and ostream classes are derived. The iostream class is derived from both istream and ostream classes.   Following table lists out some of the stream classes and their contents: Data which

The post What are stream classes in C++ Programming appeared first on Coding Security.


What are stream classes in C++ Programming
read more

What are Macro Substitution Directives in C programming

Macro substitution is a process where an identifier in a program is replaced by a predefined string composed of one or more tokens. The preprocessor accomplishes this task under the direction of #define statement. This statement, usually known as a macro definition takes the following form:   If this statement is included in the program at the beginning, then the preprocessor replaces every occurrence of the identifier in the source code by the string. Note: Care should be taken that there is no space between the # and the word define. Also there should be atleast a single space between

The post What are Macro Substitution Directives in C programming appeared first on Coding Security.


What are Macro Substitution Directives in C programming
read more

Rabu, 18 Januari 2017

How to use graphics class in AWT (java programming)

In GUI applications, we can use Graphics class of java.awt package to create various graphics like lines, rectangles, circles, polygons etc. Let’s look at some of the methods available in the Graphics class: void drawLine(int startX, startY, endX, endY) – Used to draw a line between twi points. void drawRect(int startX, int startY, int width, int height) – Used to draw a rectangle starting from the top left corner with the given width and height. The coordinates of the top left corner of the rectangle are startX and startY. void fillRect(int startX, int startY, int width, int height) – Used to draw a

The post How to use graphics class in AWT (java programming) appeared first on Coding Security.


How to use graphics class in AWT (java programming)
read more

How to use deligation event model in java programming

In this article we will learn about using delegation event model i.e., how to implement event handling in Java programs.   Following are the basic steps in using delegation event model or for handling events in a Java program: Implement the appropriate listener interface. Register the listener with the source. Provide appropriate event handler to handle the event raised on the source.   Key Events Handling Following is a Java program which handles key events. In the program when the user types characters in the text field, they are displayed in a label below the text field. 1 2 3

The post How to use deligation event model in java programming appeared first on Coding Security.


How to use deligation event model in java programming
read more

Selasa, 17 Januari 2017

The entire classification of functions in C programming

Based on the parameters and return values, functions can be categorized into four types. They are: Function without arguments and without return value. Function without arguments and with return value. Function with arguments and with return value. Function with arguments and without return value. Function without arguments and without return value In this type of functions there are no parameters/arguments in the function definition and the function does not return any value back to the calling function. Generally, these types of functions are used to perform housekeeping tasks such as printing some characters etc. Example: 1 2 3 4 5

The post The entire classification of functions in C programming appeared first on Coding Security.


The entire classification of functions in C programming
read more

How to throw the exception of Class Type in C++

Instead of throwing exceptions of pre-defined types like int, float, char, etc., we can create classes and throw those class types as exceptions. Empty classes are particularly useful in exception handling. Following program demonstrates throwing class types as exceptions: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 #include<iostream> using namespace std; class ZeroError {}; void sum() { int a, b; cout<<“Enter a and b values: “; cin>>a>>b; if(a==0 || b==0) throw ZeroError(); else cout<<“Sum is: “<<(a+b); } int main()

The post How to throw the exception of Class Type in C++ appeared first on Coding Security.


How to throw the exception of Class Type in C++
read more

What is the composition of Style rule in CSS

A style sheet contains several rules (CSS rules). A CSS rule is made of two elements: a selector and one or more declarations enclosed in braces ({}). The syntax for a CSS rule is shown below: 1 2 3 4 5 6 selector {     declaration1;     declaration2;     … } Syntax of a CSS style rule can be understood clearly by looking at the figure below: The selector specifies the HTML element to which the presentation effects should be applied and the declaration contains two parts: property-name and property-value. A HTML element can have several presentational properties and corresponding property values. An

The post What is the composition of Style rule in CSS appeared first on Coding Security.


What is the composition of Style rule in CSS
read more

Senin, 16 Januari 2017

What is the use of the extern storage class in C programming

Storage classes define the longevity and scope of variables and functions. There are two types of storage classes: automatic and static. There are several storage class specifiers: auto: this is the default storage class specifier for variables defined inside a function. auto can be used only inside functions. Variables declared auto will automatically have their storage allocated on entry to a function and deallocated when the function exits. auto variables contain garbage until explicitly initialised. Use of auto is archaic and there is no need to use it. register: this storage class specifier can be used to indicate to the

The post What is the use of the extern storage class in C programming appeared first on Coding Security.


What is the use of the extern storage class in C programming
read more

5 Best Video Tutorials for learning NodeJs

Node.js is an open-source, cross-platform JavaScript runtime environment for developing a diverse variety of tools and applications. Although Node.js is not a JavaScript framework,many of its basic modules are written in JavaScript, and developers can write new modules in JavaScript. The runtime environment interprets JavaScript using Google’s V8 JavaScript engine. Node.js has an event-driven architecture capable of asynchronous I/O. These design choices aim to optimize throughput and scalability in Web applications with many input/output operations, as well as for real-time Web applications (e.g., real-time communication programs and browser games). The Node.js distributed development project, governed by the Node.js Foundation, is

The post 5 Best Video Tutorials for learning NodeJs appeared first on Coding Security.


5 Best Video Tutorials for learning NodeJs
read more

A solution for most of the common android problems

Android phones and tablets are very easy to use and usually when they are trouble-free. But sometimes your phone may be lagged or some apps don’t work properly or slow in your device as well as there are many others errors.So here we will try to cover most common Android problems and show you how to solve those common problems. ANDROID PROBLEMS AND SOLUTIONS RUNNING OUT OF MEMORY This is one of the most common problems for the Android users who has low ram.There are many reasons for this particular problem, but the cache can often get too full to allow

The post A solution for most of the common android problems appeared first on Coding Security.


A solution for most of the common android problems
read more

Minggu, 15 Januari 2017

How form data processing is done in PHP

One of the applications of PHP is processing the data provided by the users in (X)HTML forms. PHP provides two implicit arrays $_GET and $_POSTwhich are global variables and are accessible anywhere in a PHP script. The array $_GET is used when the attribute method of the form tag is set to GET and the array $_POST is used when the attribute method of the form tag is set to POST. Both arrays contain the form data stored as key-value pairs, where key contains the value of name attribute of the form element and value contains the value of the

The post How form data processing is done in PHP appeared first on Coding Security.


How form data processing is done in PHP
read more

How to perform URL rewriting in Servlets

In this method we keep track of the data by passing the data as a query string from one page to another page. A query string starts with ? symbol and is followed by set of key-value pairs. Each pair is separated using the & symbol. Passing huge amount of data using query string is cumbersome. This method is recommended only when the data that is needed to be passed is very less. Following example demonstrates passing data using query string:   index.html 1 2 3 4 5 6 7 8 9 10 <!DOCTYPE html PUBLIC “-//W3C//DTD HTML 4.01 Transitional//EN”

The post How to perform URL rewriting in Servlets appeared first on Coding Security.


How to perform URL rewriting in Servlets
read more

How to style XML documents using XSLT and CSS

This article explains styling xml documents using CSS and XSLT. Styling information can be specified for an XML document in one of the two ways. First is by using CSS (Cascading Style Sheets) and the second is by using XSLT (eXtensible Stylesheet Language Transformations) which was developed by W3C. Although using CSS is effective, XSLT is more powerful.   Cascading Style Sheets CSS can be specified in a separate file and linked with an XML document by using the xml-stylesheet processing instruction as shown below: <?xml-stylesheet  type=”text/css”  href=”style.css” ?>  As an example consider the following XML document: 1 2 3

The post How to style XML documents using XSLT and CSS appeared first on Coding Security.


How to style XML documents using XSLT and CSS
read more

Sabtu, 14 Januari 2017

What are the attributes of the Applet Tag in java programming

Applet Fundamentals Since applet is a part of a webpage, we will learn basic things related to web pages. A web page is a collection of information (ex: Google home page, Yahoo home page etc). Web pages are generally created using HTML.   A web page contains at least four basic HTML tags: <html> : Specifies that it is the root tag. <head> : Specifies the head section of the web page. It contains meta information, page title, scripts, external style sheet links etc. <body> : Contains the content that is displayed to a user who is visiting the web

The post What are the attributes of the Applet Tag in java programming appeared first on Coding Security.


What are the attributes of the Applet Tag in java programming
read more

An example on how to use the assertions in java programming

Definition: An assertion is a condition that should be true during the program execution. They are generally used to detect errors (testing) during development of software. They have no use after the code is released to the users. They encourage defensive programming.   Creating and Using Assertions: Assertions can be created using the assert keyword. The general form of using assert keyword is as follows: assert condition; When the given condition becomes false, AssertionError is thrown by the Java run-time. The second form of assert is as follows: assert condition : expr; In the above syntax, expr can be any non-void value which will be passed on to the constructor of AssertionError

The post An example on how to use the assertions in java programming appeared first on Coding Security.


An example on how to use the assertions in java programming
read more

What is the operator precedence in Java’s Expressions

In this article you will learn about Java expressions. You will look at what is an expression in Java, what factors are considered while evaluating Java expressions and some examples which will make you clear on expressions in Java. Expression: An expression is a construct which is made up of literals, variables, method calls and operators following the syntax of Java. Every expressions consists of at least one operator and an operand. Operand can be either a literal, variable or a method invocation. Following are some of the examples for expressions in Java: How expressions are evaluated? It is common

The post What is the operator precedence in Java’s Expressions appeared first on Coding Security.


What is the operator precedence in Java’s Expressions
read more

Jumat, 13 Januari 2017

How to suspend and resume threads in java programming language

Based on the requirements sometimes you might want to suspend, resume or stop a thread. For doing such operations on a thread, before Java 2, thread API used to contain suspend(), resume() and stop() methods. But all these methods might lead to undesired behavior of the program or machine. For example, these methods might lead to deadlock when a thread locked and is accessing a data structure and suddenly it is suspended or stopped. All other threads will be waiting indefinitely for gaining access to the data structure. Because of this drawback of suspend(), resume() and stop() methods, they have been deprecated (should not

The post How to suspend and resume threads in java programming language appeared first on Coding Security.


How to suspend and resume threads in java programming language
read more

Why should you choose java as your primary programming language

Java is a high-level object oriented programming language and computing platform developed by Sun Microsystems and released in 1995. With more than 9 million developers worldwide, java enables us to develop and deploy applications and services. From laptops to data centers, game consoles to super computers and cell phones to the Internet, java is everywhere. Why Choose java? Although there are many reasons why a software developer choose java, below are some of the popular reasons: Develop software on one platform and deploy it on virtually any other platform. Create programs that can run in a web browser and access

The post Why should you choose java as your primary programming language appeared first on Coding Security.


Why should you choose java as your primary programming language
read more

What is the difference between interface and class in Java Programming

Differences between interface and a class Objects can be created for classes, where as it is not possible for interfaces. Classes can contain methods with body, where as it is not possible in interfaces. Classes can contain variables, where as it is not possible in interfaces. Some classes can be final, where as interfaces cannot be declared as final. Some classes can be abstract, where as interfaces cannot be declared as abstract. Various access specifiers like public or private or default can be applied to classes, where as only public or default access specifier is applicable for top-level interface.   Defining an Interface The definition of an interface is very much similar to

The post What is the difference between interface and class in Java Programming appeared first on Coding Security.


What is the difference between interface and class in Java Programming
read more

Kamis, 12 Januari 2017

How to check validity of the form data using javascript

One of the best uses of client-side JavaScript is the form validation. The input given by the user can be validated either on the client-side or on the server-side. By performing validation on the client-side using JavaScript, the advantages are less load on the server, saving network bandwidth and quicker response for the users. Form input can be validated using different events, but the most common event used is submit i.e when the submit button is clicked. Corresponding attribute to be used is onsubmit of the form tag. Let’s consider a simple form as shown below: 1 2 3 4

The post How to check validity of the form data using javascript appeared first on Coding Security.


How to check validity of the form data using javascript
read more

How to interpret strings as packed binary using Python’s struct

This module performs conversions between Python values and C structs represented as Python strings. This can be used in handling binary data stored in files or from network connections, among other sources. It uses Format Strings as compact descriptions of the layout of the C structs and the intended conversion to/from Python values. The module defines the following exception and functions: exception struct.error Exception raised on various occasions; argument is a string describing what is wrong. struct.pack(fmt, v1, v2, …) Return a string containing the values v1, v2, ... packed according to the given format. The arguments must match the

The post How to interpret strings as packed binary using Python’s struct appeared first on Coding Security.


How to interpret strings as packed binary using Python’s struct
read more

There are many vulnerabilities in NodeJs according to Developers

Node Js has become the standard web programming language since the 3rd quarter of 2016 many organizations use Node Js according to their stats 200 countries use Node Js as their primary programming language. Mr.Gavin Vickery, CTO of web app builder Input Logic inc. Vickery made their switch to Node.js from Python programming at the end of  2015, mostly for web backend devs. But he soon grew dissatisfied with the promise of Node.js, writing early in 2016 that Node.js was “easy to learn,” especially for those who know JavaScript language, but “impossible to master.” He described the Node ecosystems, particularly

The post There are many vulnerabilities in NodeJs according to Developers appeared first on Coding Security.


There are many vulnerabilities in NodeJs according to Developers
read more

Rabu, 11 Januari 2017

What is the Character Set of the C programming Tokens

A programming language is designed to help process certain kinds of data consisting of numbers, characters and strings and to provide useful output known as information. The task of processing data is achieved by writing instructions. These set of instructions is known as a program. Programs are written using words and symbols according to the rigid rules of the programming language known as syntax.   Character Set The characters that can be used to form words, numbers and expressions depend upon the computer on which the program is run. The characters in C, are grouped into the following four categories:

The post What is the Character Set of the C programming Tokens appeared first on Coding Security.


What is the Character Set of the C programming Tokens
read more

How to open a file in C programming

If the user wants to store data or read data from a file in the secondary memory, the user must specify certain things about the file to the operating system. They are: Filename Data Structure Purpose Filename is the name of the file. It is a collection of characters that make up a valid filename for the operating system. It may contain two parts: a primary name and optional period with the etxtension. Some valid file names are: abc.txt prog.c sample.java store Data Structure of a file is defined a FILE in the C library. Therefore, all files should be

The post How to open a file in C programming appeared first on Coding Security.


How to open a file in C programming
read more

How to use functions and substructures in C programming

In C, structures can be nested. A structure can be defined within in another structure. The members of the inner structure can be accessed using the variable of the outer structure as shown below: 1 outer–struct–variable.inner–struct–variable.membername An example for a nested structure is shown below: 1 2 3 4 5 6 7 8 9 10 11 12 struct student { struct { char fname; char mname; char lname; }name; char grade; }; struct student s1; strcpy(s1.name.fname, “satish”); In the above example, student is the outer structure and the inner structure name consists of three members: fname, mname and lname.  

The post How to use functions and substructures in C programming appeared first on Coding Security.


How to use functions and substructures in C programming
read more

Selasa, 10 Januari 2017

Best libraries to work with javascript Grids

A data grid can help address concerns of HTML tables with large data sets by providing features like sorting, filtering, searching, pagination and even in-line editing for your tables.Here in this article we make a list of 5 Best JavaScript Grid Libraries for developers, by which they can easily add grid functionality to their tables and can perform several functions like paging, sorting and filtering on large data sets.  BEST JAVASCRIPT GRID LIBRARIES FANCYGRID FancyGrid is a JavaScript grid library with charts integration and server communication. FancyGrid is integrated(data binding) with chart libraries.It’s Intelligent modules system auto detects and loads needed modules. Features: Paging Sorting

The post Best libraries to work with javascript Grids appeared first on Coding Security.


Best libraries to work with javascript Grids
read more

Top 5 animations visit if you want to be CSS pro

CSS 3 has so many features to enhance your website design.CSS3 made a big difference in the webdesign industry. Lots of new features added to make dynamic websites.With CSS3 and HTML5, one can now create extremely modern and very stylish web designes, loaded with effects and animations. Here in this post we have gather 12 best example of CSS animation with source code. Cascading Style Sheets (CSS) is a style sheet language used for describing the presentation of a document written in a markup language.Although most often used to set the visual style of web pages and user interfaces written

The post Top 5 animations visit if you want to be CSS pro appeared first on Coding Security.


Top 5 animations visit if you want to be CSS pro
read more

Go Kills Java,C and Python as the fastest growing programming language of the year

Google’s Go was 2016’s biggest gainer in Tiobe’s indexes of language popularities, as the top title on the list all slipped year over years. Claiming the crown of Tiobe’s programming languages of the year, Go gained 2.16 percentage point from a year ago, with a rating of 2.325 percentile. It was ranked in 13th place this month and was in 54th place in the January 2016. Tiobe ranking are based on a formula assessing searche on languages in popular search engines such as Google, Bing, and Wikipedia. “The main drivers behind Go’s success are its ease of learning and pragmatic

The post Go Kills Java,C and Python as the fastest growing programming language of the year appeared first on Coding Security.


Go Kills Java,C and Python as the fastest growing programming language of the year
read more

Senin, 09 Januari 2017

How to declare attributes in DTD XML

The attributes of an element are declared separately from the element declaration. The declaration of an attribute is as shown below: <!ATTLIST  element_name  attribute_name  attribute_type  >  If more than one attribute is declared for a given element, such declarations can be combined as shown below: 1 2 3 4 5 6 <!ATTLIST  element_name       attribute_name_1  attribute_type  default_value_1       attribute_name_2  attribute_type  default_value_2       —       attribute_name_n  attribute_type  default_value_n > There are ten different attribute types. Among them, most frequently used type if CDATA, which specifies character data (any string characters except < and &). The default value of an attribute can be an actual value or a requirement for the value of

The post How to declare attributes in DTD XML appeared first on Coding Security.


How to declare attributes in DTD XML
read more

How to import and use your own packages in java programming

There are multiple ways in which we can import or use a package. They are as follows: Importing all the classes in a package. Importing only necessary classes in a package. Specifying the fully qualified name of the class. First way is to import all the classes in a package using the import statement. The import statement is placed after the package statement if any and before all class declarations. We can import all the classes in a package as shown below: import  mypackage.*; * in the above line denotes all classes within the package mypackage. Now you are free to directly use all the

The post How to import and use your own packages in java programming appeared first on Coding Security.


How to import and use your own packages in java programming
read more

What is the extern storage class in C Programming

The extern storage class specifies that the variable is declared in some part of the program. Generally this storage class is used to refer global variables in a program. Note that extern variables cannot be initialized. The scope of a extern variable is throughout the entire program and the lifetime is until the program completes its execution. In a multi-file program, a global variable in one file can be accessed from another file by using the storage class extern. Syntax for declaring a externvariable is as shown below: static The static storage class can be applied to both local variables

The post What is the extern storage class in C Programming appeared first on Coding Security.


What is the extern storage class in C Programming
read more

Minggu, 08 Januari 2017

How to pass two dimensional Arrays in C Programming

We can also pass two-dimensional arrays as parameters to a function. While passing two-dimensional arrays as parameters you should keep in mind the following things: In the function declaration you should write two sets of square brackets after the array name. You should specify the size of the second dimension i.e., the number of columns. In the function call you should write two sets of square brackets after the array name. Also you should specify the size of the second dimension i.e., the number of columns. In the function call, it is enough to pass the name of the array

The post How to pass two dimensional Arrays in C Programming appeared first on Coding Security.


How to pass two dimensional Arrays in C Programming
read more

What is the difference between Local and Global Variables in Programming

A variable is a memory location inside memory which is referred using a name. The value inside a variable changes throughout the execution of the program. Based on where the variable is declared in the program, variables can be divided into two types. They are: Local Variables Global Variables   Local Variables A variable is said to be a local variable if it is declared inside a function or inside a block. The scope of the local variable is within the function or block in which it was declared. A local variable remains in memory until the execution of the

The post What is the difference between Local and Global Variables in Programming appeared first on Coding Security.


What is the difference between Local and Global Variables in Programming
read more

What is the Basic Programming terminology

Language A language is a set of characters, words and associated grammar rules which is used for communication between two human beings either spoken or written. Examples: Telugu, Hindi, English etc. C is one of the most widely used programming languages across the world. Programming related concepts of many programming languages were derived from C. C was developed by Dennis Ritchie.   This C Programming tutorial is intended for beginners who have no idea of programming. You are suggested to follow the tutorial in top-down fashion   The language became more popular after publication of the book, “The C Programming

The post What is the Basic Programming terminology appeared first on Coding Security.


What is the Basic Programming terminology
read more

Sabtu, 07 Januari 2017

What is the action event interface in java programming

The event delegation model contains two main components. First are the event sources and second are the listeners. Most of the listener interfaces are available in the java.awt.event package. In Java, there are several event listener interfaces which are listed below:   ActionListener  This interface deals with the action events. Following is the event handling method available in the ActionListener interface: void actionPerformed(ActionEvent ae)   AdjustmentListener This interface deals with the adjustment event generated by the scroll bar. Following is the event handling method available in the AdjustmentListener interface: void adjustmentValueChanged(AdjustmentEvent ae)   ComponentListener This interface deals with the component events.

The post What is the action event interface in java programming appeared first on Coding Security.


What is the action event interface in java programming
read more

What is the component adapter in adapter classes

In this article we will learn about adapter classes which are used to simplify the event handling process. Sample Java programs are also provided.   Adapter classes are a set of classes which can be used to simplify the event handling process. As we can see in the mouse event handling program here, even though we want to handle only one or two mouse events, we have to define all other remaining methods available in the listener interface(s). To remove the aforementioned disadvantage, we can use adapter classes and define only the required event handling method(s). Some of the adapter

The post What is the component adapter in adapter classes appeared first on Coding Security.


What is the component adapter in adapter classes
read more

Here is the list of every event Trigger in javascript

The programming which allows computations based on the activities in a browser or by the activities performed by the user on the elements in a document is known as event-driven programming. An event is the specification (essentially an object created by the browser and JavaScript) of something significant has occurred. Examples of events are click, submit, keyup etc. In JavaScript all the event names are specified in lowercase. An event handler (essentially a function) is a set of statements (code) that handles the event. Below table lists most commonly used events and their associated tag attributes: Event Tag Attribute blur

The post Here is the list of every event Trigger in javascript appeared first on Coding Security.


Here is the list of every event Trigger in javascript
read more

Jumat, 06 Januari 2017

How to manipulate user defined objects in Programming

Creation and Manipulation of User Defined Objects An object is a real world entity that contains properties and behaviour. Properties are implemented as identifiers and behaviour is implemented using a set of methods. An object in JavaScript doesn’t contain any predefined type. In JavaScript the new operator is used to create a blank object with no properties. A constructor is used to create and initialize properties in JavaScript. Note: In Java new operator is used to create the object and its properties and a constructor is used to initialize the properties of the created object. An object can be created

The post How to manipulate user defined objects in Programming appeared first on Coding Security.


How to manipulate user defined objects in Programming
read more

Templates vs Macros which is better to use in Programming?

As templates and macros perform similar tasks, we need know what is the difference between them. Following are the differences between templates and macros: Guidelines for Using Template Functions   While using template functions, programmer must take care of the following:   Generic Data Types   Every template data type (or generic data type) should be used as types in the function template definition as type of parameters. If not used, it will result in an error. Consider the following example which leads to an error: 1 2 3 4 5 template<class Type> void summ(int x, int y) //Error since

The post Templates vs Macros which is better to use in Programming? appeared first on Coding Security.


Templates vs Macros which is better to use in Programming?
read more

What are associative containers in Programming

There is no sequential ordering of elements. Data is sorted while giving input. Supports direct access of elements using keys. Data is stored as a tree. They facilitate fast searching, insertion, and deletion. Not efficient for sorting and random access. Examples of associative containers are: Set, multiset, Map, and multimap.   Set and multiset: Store multiple elements and provide functions to manipulate them using their keys. A set does not allow duplicate elements. But a multiset allows duplicate elements. They are defined in the header file <set>.   Map and multimap: Stores the elements as pair of key and value.

The post What are associative containers in Programming appeared first on Coding Security.


What are associative containers in Programming
read more

Kamis, 05 Januari 2017

What is process based multi tasking in java programming

Multitasking: Ability to execute two or more tasks in parallel or simultaneously is known as multitasking. Multitasking is of two types: 1) Process based multitasking and 2) Thread based multitasking. Process based multitasking: Executing two or more processes simultaneously is known as process based multitasking. For example, we can listen to music and browse internet at the same time. The processes in this example are the music player and browser. Thread based multitasking: Thread is a part of process i.e., a process can contain one or more threads. If two or more such threads execute simultaneously, it is known as thread

The post What is process based multi tasking in java programming appeared first on Coding Security.


What is process based multi tasking in java programming
read more

How to access structure members in Programming

We can access and assign values to the members of a structure in a number of ways. As mentioned earlier, the members themselves are not variables. They should be linked to the structure variables in order to make them meaningful members. The link between a member and a variable is established using the member operator ‘ . ‘ which is also known as dot operator or period operator. The syntax for accessing a structure member is as shown below: 1 structure–varaible.membername Examples of accessing the members of the student structure are shown below: 1 2 student1.name student1.age   Structure Initialization

The post How to access structure members in Programming appeared first on Coding Security.


How to access structure members in Programming
read more

How to make arguments a variable length

In this article we will look at what is variable length arguments or varargs is and how to use variable length arguments in methods to solve the complexity of a Java program.   There might be some situations while creating methods, where the programmer might not know how many arguments are needed in the method definition or how many arguments are going to be passed at run-time by the user. Prior to Java 5, there were a couple of workarounds for this problem but was often complex or error prone.   With Java 5, a new feature called varargs was

The post How to make arguments a variable length appeared first on Coding Security.


How to make arguments a variable length
read more

Rabu, 04 Januari 2017

DeadPool Make the top of Torrented Movies list in 2016

Below we have compiled a list of the most-torrented films in 2016 (irregardless of their release date). The data is estimated by TorrentFreak based on several sources, including download statistics reported by public BitTorrent trackers. Deadpool Wade Wilson (Ryan Reynolds) is a former Special Forces operative who now works as a mercenary. His world comes crashing down when evil scientist Ajax (Ed Skrein) tortures, disfigures and transforms him into Deadpool. The rogue experiment leaves Deadpool with accelerated healing powers and a twisted sense of humor. With help from mutant allies Colossus and Negasonic Teenage Warhead (Brianna Hildebrand), Deadpool uses his

The post DeadPool Make the top of Torrented Movies list in 2016 appeared first on Coding Security.


DeadPool Make the top of Torrented Movies list in 2016
read more

This new tool lets you download the Netflix Videos

There is new tool on the internet which let’s you download the NetFlix videos for free.which is under the identity of the Free Netflix Downloader. A few weeks ago Netflix announced that it would allow user to download a small selection of video for offline use, on mobile device. While this is a great step forward, there’s also a large group of user who would like to do the same with other video on other operating systems. Free Netflix Downloader is applications that offers exactly this. Developed by DVDVideoSoft inc , it is the first Windows applications that allow people

The post This new tool lets you download the Netflix Videos appeared first on Coding Security.


This new tool lets you download the Netflix Videos
read more

Top 10 pirated Movies of the week #1

This is the first article of this kind where we calculate the Top Torrented Movies of the Week if you want more of this kind articles please comment us below we will be sure to provide you with a article like this for every week . This week we have 10 movies that are Jack Reacher : Never Go Back Investigator Jack Reacher (Tom Cruise) springs into action after the arrest of Susan Turner (Cobie Smulders), an Army major accused of treason. Suspecting foul play, Jack embarks on a mission to prove that the head of his old unit is

The post Top 10 pirated Movies of the week #1 appeared first on Coding Security.


Top 10 pirated Movies of the week #1
read more

7 Best Resources to learn Swift Programming

Programmers who want to develop apps for iOS, Mac, tvOs, watch OS and want to learn a new programming language and learn the Apple’s CoCoa Framework. What is the use of Swift Programming language? As per the reports of Website Development Companies, Swift language has been developed by Apple in order to simplify the code used in Apple based OS’s. Being compatible with Objective-C  and C languages, the language can also be used beyond the Apple OS and iPhone apps, developers are getting quite attracted towards this platform in order to develop better app. Seven sources from where you can learn

The post 7 Best Resources to learn Swift Programming appeared first on Coding Security.


7 Best Resources to learn Swift Programming
read more

What is the most popular programming language in the enterprise

Programmers have high demands these days because of the Growing Startups if one is interested in the best carrier and want to make the best of his life they need to know the popular programming language in the enterprise. The stats were imported from the ZDNET, on the search keyword of the popular programming language, they have prepared a pretty good list that uses the data from the PYPL(popularity of the Programming language), primary , which looks at the popular programming languages on the Google and uses a search engine to aggregate the results. Programming languages differ from natural languages in

The post What is the most popular programming language in the enterprise appeared first on Coding Security.


What is the most popular programming language in the enterprise
read more

10 Must Apps for the Programmers if they want to be professional

Every Programmer should know that with a well-equipped hardware we need a good software to utilize the resources as a programmer you will code every day. Here are some apps that will help you on the Go 1.DroidEdit If you want a code editor for android DroidEdit is the Best Editor for you, compatableI can say it is packed with features like deep search and keyboard shortcuts.It also does the Code highlighting for C++, Java, Ruby and may more. 2.AIDE If you are in need for a tool that transfers the code to the Android phones from the Eclipse Project

The post 10 Must Apps for the Programmers if they want to be professional appeared first on Coding Security.


10 Must Apps for the Programmers if they want to be professional
read more

Senin, 02 Januari 2017

How Data Redirection works in Servlets

sendRedirect() is executed on client side, whereas forward() is executed on server side. sendRedirect() works only with HTTP, whereas forward() works with any protocol. sendRedirect() takes two request and one response to complete, where as only one call is consumed in the case of the forward() method. sendRedirect() can be used to redirect a user to a resource on any server on the web. Whereas forward() can be used to redirect a user to a resource on the same server where the application or the page resides.   Following example demonstrates redirecting a user using sendRedirect() and forward() methods:  

The post How Data Redirection works in Servlets appeared first on Coding Security.


How Data Redirection works in Servlets
read more

How to work with Http Servlet Request interface in java

The HttpServletRequest interface is a subtype of ServletRequest interface. Implementation for this interface is provided by the servlet container. The HttpServletRequest interface object allows us to access the data available in the HTTP headers and HTTP requests. Following methods helps us to access the header information: String getHeader(String) Enumeration getHeaders(String) Enumeration getHeaderNames()   Following methods helps us to access the path information: String getContextPath() String getServletPath() String getPathInfo() String getRequestURI()   HttpServletResponse Interface   The HttpServletResponse is a subtype of ServletResponse interface. Implementation for this interface is provided by the servlet container. The HttpServletResponse interface object let’s us to specify

The post How to work with Http Servlet Request interface in java appeared first on Coding Security.


How to work with Http Servlet Request interface in java
read more

What is access control for classes and variables in java

In this article we will look at access control in Java. We will learn about four access modifiers: public, protected, default and private along with java code examples.   Access Control Access control is a mechanism, an attribute of encapsulation which restricts the access of certain members of a class to specific parts of a program. Access to members of a class can be controlled using the access modifiers. There are four access modifiers in Java. They are: public protected default private If the member (variable or method) is not marked as either public or protected or private, the access modifier for that

The post What is access control for classes and variables in java appeared first on Coding Security.


What is access control for classes and variables in java
read more

Minggu, 01 Januari 2017

How to use a hex manipulator in unformatted Console I/O in C++ Programming

Data which is received by the program without any modifications and sent to the output device without any modifications is known as unformatted data. On the other hand, sometimes we may want to apply some modifications to the actual data that is being received or sent. For example, we might want to display an integer in hexadecimal format in the output, leave some whitespace when printing a number and adjustments in the decimal point. Such modified data in known as formatted data.   As an example for formatted data, if we want to display a decimal number in hexadecimal format,

The post How to use a hex manipulator in unformatted Console I/O in C++ Programming appeared first on Coding Security.


How to use a hex manipulator in unformatted Console I/O in C++ Programming
read more

How to make a pointer point to a derived class in C++ Programming

A base class pointer can point to a derived class object. But, a derived class pointer can never point to a base class object. Following program demonstrates object slicing using a base class pointer: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 #include<iostream> using namespace std; class A { protected: int x; public: void show() { cout<<“x = “<<x<<endl; } }; class B : public A { protected:

The post How to make a pointer point to a derived class in C++ Programming appeared first on Coding Security.


How to make a pointer point to a derived class in C++ Programming
read more

What are the Rules to implement Virtual Functions

Following points must be remembered while working with virtual functions: Virtual functions must be members of a class. Virtual functions must be created in public section so that objects can access them. When virtual function is defined outside the class, virtual keyword is required only in the function declaration. Not necessary in the function definition. Virtual functions cannot be static members. Virtual functions must be accessed using a pointer to the object. A virtual function cannot be declared as a friend of another class. Virtual functions must be defined in the base class even though it does not have any

The post What are the Rules to implement Virtual Functions appeared first on Coding Security.


What are the Rules to implement Virtual Functions
read more