Author: sujan maka

User defined methods in java

User defined methods in java: Functions are called methods in java. Like in C, java programming has similar user defined methods. There are basically four types of user defined methods. They’re: Methods with parameter and with return typeMethods with parameter and without return typeMethods without parameter and with return typeMethods without parameter and without return

Break and Continue Statement in Java

Break and continue statement in java : Like goto statement in c, there is break and continue statement to transfer control in the program. Whenever certain condition matches in the code, you may won’t to transfer your code’s flow to some other parts of the code. In such scenario, we use break and continue statement.

C Programming for beginners

C Programming for beginners. C is a high level and general purpose programming language that is fast, portable and available in all platforms. It is a procedural programming language which was initially developed by Dennis Ritchie between 1969 and 1973. The main features of C language include low-level access to memory, simple set of keywords,

Using postman to test REST API

Postman to test REST API. We’ve created REST API in our previous tutorial. Now we’re going to test our REST API using postman. You can download postman from here. After downloading postman, you’ll get something like this. Note: make sure you’ve successfully deployed EJB-JPA-CRUD-Rest in glassfish server. Before using postman, know the some HTTP methods. GET

Rest API with EJB, JPA and CRUD operation

In this tutorial, you’ll learn how to develop Rest API with EJB, JPA and CRUD operation. Before going through this tutorial make sure you’ve gone through my previous tutorial. In the previous tutorial, I’ve clearly mentioned how to use glassfish server and make connection pools, and as well as using Sqlyog Database. After this tutorial, I’ll

Java Program that will encode a number n as an array that contains the prime numbers

The fundamental theorem of arithmetic states that every natural number greater than 1 can be written as a unique product of prime numbers. So, for instance, 6936=2*2*2*3*17*17. A method named encodeNumber will encode a number n as an array that contains the prime numbers that, when multipled together, will equal n. So encodeNumber(6936) would return