Blog of Java Programmer

Blog of Java Programmer

Share

25/08/2021

Sort digits with ArrayList:

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.ArrayList;

public class Solution {
public static void main(String[] args) throws IOException {
// insert code here
BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));

ArrayList mainList = new ArrayList();
for (int i = 0; i < 20; i++) {
mainList.add(Integer.parseInt(reader.readLine()));
}

ArrayList multipleThree = new ArrayList();
ArrayList multipleTwo = new ArrayList();
ArrayList multipleThreeAndTwo = new ArrayList();

for (int i = 0; i < mainList.size(); i++) {
Integer figure = mainList.get(i);

if (figure % 3 == 0 || figure % 2 == 0) {
if (figure % 3 == 0) {
multipleThree.add(figure);
}
if (figure % 2 == 0) {
multipleTwo.add(figure);
}
}else {
multipleThreeAndTwo.add(figure);
}
}

JPA persistence.xml Example | Examples Java Code Geeks - 2021 03/03/2021

https://examples.javacodegeeks.com/enterprise-java/jpa/java-persistence-xml-example/

JPA persistence.xml Example | Examples Java Code Geeks - 2021 In this tutorial, we will show how to implement the Java Persistence API and define the JPA Persistence Units with EclipseLink and MySQL in Java.

13/02/2021

Эта страница будет временной площадкой для блога, основной сайт разрабатывается!
Let's continue to discuss about Spring and java Android development!

13/02/2021

My repository is closed:
https://bitbucket.org/dashboard/overview
Contact with me for communication

Log in with Atlassian account Log in to Jira, Confluence, and all other Atlassian Cloud products here. Not an Atlassian user? Sign up for free.

Want your school to be the top-listed School/college in Kyiv?
Click here to claim your Sponsored Listing.

Category

Culinary Team

Attire

Website

Address


Kyiv