Skip to content

Instantly share code, notes, and snippets.


Block or report user

Report or block ssinganamalla

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
ssinganamalla /
Created Jan 12, 2016
Load config properties file located in resources directory
public static ApplicationProperties loadProperties() {
Properties prop = new Properties();
InputStream input = null;
try {
ClassLoader classloader = Thread.currentThread().getContextClassLoader();
input = classloader.getResourceAsStream("");
// load a properties file
ssinganamalla / renamedb.sql
Created Aug 27, 2015
rename database name in postgres
View renamedb.sql
//delete the user sessions
SELECT pg_terminate_backend( pid )
FROM pg_stat_activity
WHERE pid <> pg_backend_pid( )
AND datname = 'oldname';
public class Program
yes thats me
yes thats me
you will have to use Double Dispatch in order for u to print 2 statements
public static void main(String[] args)
ssinganamalla /
Last active Oct 9, 2015
Intersection of two linkedlists
/*Write a program to find the node at which the intersection of two singly linked lists begins.
For example, the following two linked lists:
A: a1 → a2
c1 → c2 → c3
B: b1 → b2 → b3
Given a list of non negative integers, arrange them such that they form the largest number.
For example, given [3, 30, 34, 5, 9], the largest formed number is 9534330.
Note: The result may be very large, so you need to return a string instead of an integer.
public class MaxNumber {
String getLargestNumber(List<Integer> numbers) {
package com.mycompany.tree;
public class Node {
public int value;
public Node left;
public Node right;
public int level;
public Node(int value) {
public User findByEmail(String email) {
Query query = this.em.createQuery("SELECT user FROM User u where :theemail");
query.setParameter("theemail", email);
return (User) query.getSingleResult();
View Maincs.html
@*Empty div otherwise the deployment is not successful. keep the hack, till u figure out*@
ViewBag.Title = "AFE Administration";
View layoutcs.html
<!DOCTYPE html>
<link href="@Url.Content("../../Scripts/resources/AfeAdmin-all.css")" rel="stylesheet" type="text/css" />
<!-- TO GO IN DEV MODE: comment the line -->
<!-- <script src="@Url.Content("../../Scripts/all-classes.js")" type="text/javascript"></script>-->
View extjsindex.html
<meta charset="UTF-8">
<!-- <x-compile> -->
<!-- <x-bootstrap> -->
<link rel="stylesheet" href="bootstrap.css">
<script src="ext/ext-dev.js"></script>
<script src="bootstrap.js"></script>
You can’t perform that action at this time.