Here is a simple code to check clojure vector contains
(filter #(= 4 %) [1 2 3 4])
Solutions of some of the common programming problems faced by a programmer in his daily life
(filter #(= 4 %) [1 2 3 4])
(let [today (java.time.LocalDate/now)]
(println (.format today (. java.time.format.DateTimeFormatter ofPattern "dd MMM, yyyy")))
(println (str "Year " (.getYear today)))
(println (str "Day of Month " (.getDayOfMonth today)))
)
import java.sql.*;
public class SqlConnect {
public static void main(String [] args) {
try{
Class.forName("com.mysql.jdbc.Driver");
System.out.println("Driver Loaded...");
String url = "jdbc:mysql://localhost:3306/your database Name";
Connection con = DriverManager.getConnection(url,"root","mysql");
System.out.println("Connection established.....");
con.close();
} catch(Exception ex) {
System.out.println("File Not found");
}
}//end main
}//end class
The Code is quite self explanatory but if you have any problems in understanding it. Please Let me know.