Google Cloud Platform

Hello folks,

Hope you all are doing fine, and reading this in all your good health.

Recently most of us have started reading and studying lots of things specially related to our skills set. One thing which keeps me going forward is Learning in this lockdown which keeps me up awake late in night.

As a developer you need to evolve continuously, because of the new trends or new skills set required at work. In general whenever, we get this chance to learn something new, we try to pick up those things which are right now in demand and in future will help you go further and also keep you safe from the fear of stagnation.

That’s why I have started learning about Google Cloud Platform popularly known as GCP. I will keep you update with my findings and learnings.

Till then be safe and stay strong.

~ Peace.

Homebrew behind a proxy

Hi Guys,

I wanted to write this post as I was facing issues while installing formula use homebrew command on Mac OS behind proxy, finally I was able to do it using info given on this page.

Its really simple just use the http_proxy or https_proxy before the brew install command or any brew command you want to run behind proxy.

e.g.

https_proxy=https://username:password@proxy:port brew install apache-spark

http_proxy=http://username:password@proxy:port brew install $other_formula

Also one can set the git config settings for http.proxy and https.proxy like below:

git config –global http.proxy http://username:password@proxy:port

git config –global https.proxy https://username:password@proxy:port

These above settings will make sure to pass through proxies while brew connects to git repository.

Enjoy and thanks for reading.

 

What do you think?

I was watching this new Badminton league on Star Sports and started thinking what has started with IPL (India Premier League) and suddenly there are loads of Leagues started around the concept (Auction the player – Buy the player – Earn the profit).

This franchise system has changed the energy of the very game, where it has entered either Cricket, or Football, or Tennis or Badminton. These are few sports which are already in limelight due to the recognition at world level and Olympics. What should intrigue you is the rise of the Indian desi sport Kabbadi. This was considered as the sport of the village and rural area (mostly due to the easily available sand field for making the Kabbadi arena :)).

So come to the point what did really intrigued me to write this blog, that raised the necessity to get the answers. It is what do you think what happens to spirit of the Indian. If you remember Chak De India! movie part where Shahrukh Khan asks every state players their intro and everyone stated that they are from so so state, but he choses Vidhya because she mentioned India in her intro.

So what do you think happens to the spirit of the Fans, Players, normal people who does not take care of what is going all in this sport (because they are already too much in following Soccer, FIFA and FI) anyway who has time to go for the extra stuff. Whether the very spirit of the game raised the very truly feeling of belonging to one Nation India ( rather than they are from so so Delhi, Chennai, Mumbai or so team).

What do you think spirit of the game really raises the feeling of the one truly nation India, among all the Indian players.

Disclaimer : Keep out all the Pros sportsperson as they are already above this spirit, they are already moved to very FORCE of the sport.

 

Thanks guys reading this, I will be really happy if you can put some thoughts here. May the force be with you.

How to For Each in Hash Map in Java 8 using Lambda Expressions

Lambda Expression Java 8

In Java 1.8 (Java 8) this has become lot easier by using forEach method from Aggregate operations(Stream operations) that looks similar to iterators from Iterable Interface.

Just copy paste below statement to your code and rename the HashMap variable from hm to your HashMap variable to print out key-value pair.

HashMap<Integer,Integer> hm = new HashMap<Integer, Integer>();
/*
 *     Logic to put the Key,Value pair in your HashMap hm
 */

// Print the key value pair in one line.
hm.forEach((k,v) -> System.out.println("key: "+k+" value:"+v));

Below is the sample code that i tried using Lambda Expression. This stuff is so cool. Must try.

HashMap<Integer,Integer> hm = new HashMap<Integer, Integer>();

    Random rand = new Random(47);

    int i=0;
    while(i<100)
    {
        i++;
        int key = rand.nextInt(20);
        int value = rand.nextInt(50);
        System.out.println("Inserting key: "+key+" Value: "+value);
        Integer imap =hm.put(key,value);
        if( imap == null)
        {
            System.out.println("Inserted");
        }           
        else
        {
            System.out.println("Replaced with "+imap);
        }               
    }

    hm.forEach((k,v) -> System.out.println("key: "+k+" value:"+v));

Also one can use Spliterator for the same.

Spliterator sit = hm.entrySet().spliterator();

UPDATE


Including documentation links to Oracle Docs. For more on Lambda go to this link and must read Aggregate Operations and for Spliterator go to this link.

Data Evolution

I was reading this article from Ericsson from their Mobility November 2014 report and got to know some details on Mobile/Data trends and future of the Smart Phone with Data technologies like GPRS/EDGE/3G/4G/5G.

There was one point where they were discussing about data consumed in 2013, 2014 and what will happen in 2020. Before I go further please read regarding Data consumption terminologies at this link http://en.wikipedia.org/wiki/Megabyte

In 2013 mobile data traffic was 2 EB/month and in 2014 it is 3.2 EB/month and in 2020 it will be 25 EB/month that is 40% increase in consumption.

Also number of smart phone devices with LTE/4G capabilities are going to increase and 3G devices will remain constant.

I would really like you guys to over this report once if you want to know about mobile phone and data statistics.

http://www.ericsson.com/res/docs/2014/ericsson-mobility-report-november-2014.pdf

Thanks

Design Patterns

Cover of "Design Patterns: Elements of Re...

Cover via Amazon

Hello guys,

Last week I got a chance to attend a training on Design Patterns. I would like to share my views on that this is the best way to really learn object-oriented design. After recognizing these Patterns it will improve your coding skills to par and further in future it will make you a good developer.

Prior knowledge of any computer language is required but it will be advantage to those people who have worked upon languages related to OOPs concept. It will be easy for them to co relate their problems and easy design solution to their problems.

1. Design Patterns are solution to common design problems that developers face during designing simple/complex applications and GOF(Erich Gamma, Richard Helm, Ralph Johnson and John Vlissides) Gang Of Four identified those problems and make a series of those solutions as Design Patterns. I would recommend you all to read this book at least.

2. We can divide these 23 Design Patterns into three categories:

3. Structural Patterns are those patterns which are related to composing the classes and objects in order to form larger Structures. One can relate these patterns to common life examples like Bridge, Adapter etc. Let me write down those patterns:

  • Bridge
  • Adapter
  • Decorator
  • Composite
  • Proxy
  • Flyweight
  • Facade

4. Creational Patterns are related with Instantiating the objects, creating the good design concept while coding in order to make their use easy while developing applications, these are:

5. Behavioral Patterns  are related to Behavior of the objects, their communication with the other objects and their methods. Basically algorithmically design of the classes and their methods. These are:

  • Chain of Responsibility
  • Command
  • Interpreter
  • Iterator
  • Mediator
  • Memento
  • Observer
  • State
  • Strategy
  • Template Method
  • Visitor

So guys improve your programming skills as I am doing so right now. Please share your comments and suggestions to improve others.

Books you can read to improve your Design Patterns concept

1.  Design Patterns: Elements of Reusable Object-Oriented Software

2. Head First Design Patterns

Financial Dilemna

Is this a start of another Bubble burst – Financial? India is loosing its favourite destination for investment in the world. If you look closely you will find that most of the Blue Chip companies lost significant amount of their market capitalisation. Increasing NPAs(Non Performing Assets), rise of defaulters, reducing profit what does that mean, i mean once Banking stocks were shine of the every quarterly results. Now what else could be the reason and that is concern for middle class like us as the investors. Will you or will you not enter into this hideous, mischievous investment fund driven market?

 

Good Luck guys.

Life is tough.

It is you who needs to make the call. Call that will change the path, path of your life to the better life. It leads us to choice, choice of the life that you want to live. Choice comes in two ways, ways which are suitable to us and those which are not. Ways that shows us the path, path that leads us to the desired. Desired makes you feel, feel brings harmony to the Nature. Nature makes you feel the Music, music that creates joy. Joy that is what you wanted in first place.

 

Nokia Lumia 920 in Newyork from the verge

Image representing Nokia as depicted in CrunchBase

Image via CrunchBase

So people are shouting Switch to Lumia. Well lets see what do you have Mr. Nokia Lumia 920.

– Wireless Charging : That is something Apple does not have.

– Nokia SmartShoot lets your remove unwanted objects in photos.  That is smart.

– Pure View, Nokia Maps/Drive/Transport, Nokia City Lens

– In Slate grey, Red, and Yellow colors

– 2000mAh battery

– Carl Zeiss rear camera

– Offline Maps is the feature

– Nokia Drive for free voice navigation

– Best Viewing experience with Nokia PureMotion HD+

– 4.5 inches curved glass display

– ClearBlack displays using smart Polarizers

– Automatic brightness control in light and no light

– Qualcomm Snapdragon S4 processor

– IE10 and HTML5

– Auto upload to SkyDrive in Windows Phone 8 (WP8) not only phone photos even from third party apps photos too, totally smart

– fastest LCD display on smartphone, WXGA, higher than 720p resolution

– Super sensitivity touch allows you to touch the display with gloves good in winters

– JBL Power UP speaker for Nokia

– Integrated NFC

– Smart Shoot, it analyzes and finds the objects that are moving that is really really smart feature, very useful

– Cinemagraph is the lens to make GIF

– Whole camera assembly has springs around it that makes 50 percent better picture quality

– 100,000+ apps

Most of the stuffs from : The Verge Live Coverage  from New York. It looks Yellow and Blue is the color theme.

Reserve Bank of India

Hello Friends,

Today I am going to discuss about Reserve Bank of India (RBI). This is central bank of India.

It was established in 1934 as a private bank, government owned and it was not a commercial bank but its sole purpose was to provide basic services of Central Bank to India.

It is an agency or an institution to do traditional work of a central bank. Where Deposit, Credit can be done. Normal bank that we know are the bank which act as intermediaries between Depositors and Creditors.  Difference between Central bank and commercial bank is that Central Bank is bank of Commercial bank and Commercial banks are bank to Citizen.

Central bank works on government behalf,  like it can give pension, take income tax. It works for both government and commercial bank.

There are 27 PSU banks in India, 196 regional banks, various private banks and some international banks also like Bank of America and Citi. America has 4 central banks.

It make sure that savings are getting utilized, means savings should be in other forms of liquid cases like MFs, Share market, FDs etc.

It take care of Controlled Monitoring Expansion.

Some other institutional banks that got formed from RBI:

1964 – Industrial Development Bank of India from RBI

1982 – NABARD

1989 – National Housing Bank

RBI works as guide to these banks.

RBI works as custodian of foreign currency, controller of credit.

There is a question between RBI and government. Shall RBI works as free entity, no control from Government.

What is Deficit banking, you must be wondering: What happens When government needs money they order overdraft on their behalf to RBI and RBI release it. This is called Deficit Financing.

RBI gives guidance, advise, warning to break this deficit financing but govt ignores. So bank finds it is not good for future. Now an agreement happened between govt and RBI for limit of ordering Overdraft. So if government asks for more than the limit then RBI can decide what is good for future.

July 1991, Govt decontrol the government institution, and now almost every govt. institute is dismantling govt. control. So new economic system. no control, only market, capital power. So new situation is good but RBI should guide them.

Hope you liked my post. I will post more informative articles time to time.

The old RBI Building in Mumbai

Govt of India Mint, Behind the RBI HQ. Mumbai

Govt of India Mint, Behind the RBI HQ. Mumbai (Photo credit: Wikipedia)

The old RBI Building in Mumbai (Photo credit: Wikipedia)

How to remove extra characters in UNIX file using NotePad Plus Plus

Hi Guys,

Today i was facing some problem while viewing UNIX files on my system using NotePad ++. There were some unwanted characters in the file that were causing pain to read the file.

These are the steps how to remove those unwanted characters from the UNIX file in NPP++.

Step 1: Select the unwanted character by placing cursor right before the character and press shift+ right arrow key once.

Step 2: After selecting the character it will look like the above screen. Now you need to replace it with space ‘ ‘ character. Following screen will clear your understanding:

Step 3: Change the value in Replace with text field with ‘ ‘ single space character:

Step 4: Now just click the Replace All button and here you go smooth and clean text to read:

Thanks for reading it. I will paste some more easy to understand tricks on my site.

How to Save Battery

Hello friends,

Here are some suggestions from my side in order to save your battery. Information gathered from internet and from my experience.

1. First day of battery you should over charge it for half an hour more after your phone is showing Battery full.

2. Later days never charge it often, as Li ion battery comes with limits of number of recharge.

3. Always charge before it runs down.

4. Do not talk much on phone, so avoid long duration calls. Also good for health.

5. Use GPRS mode only when needed, so avoid those applications that syncs with the server more often. Increase the sync time if it needed be.

6. Switch off while you are travelling underground or there is no network, because battery consumption goes higher in order to increase the power of receiver to get the network signals.

7. Better suspend those applications which are in syncing mode while you are sleeping.

8. The best way of recharging battery is while phone is switched off.

9. Do not use UMTS network mode when there is no 3G network.

10. Protect it from direct sunlight.

 

Thanks guys for reading. Suggestions are welcome.

Nokia BL-5B lithium-ion battery

Image via Wikipedia

Yes, God is there!!!

Believers (film)

Image via Wikipedia

Yes, God is there…

Yet you never been to temple, you still care there is God.

Yet you never been to mountains, you still knows there is God.

Yet you never played any music, you still hear there is God.

Yet you never saw any miracles, you still see there is God.

Yet you never try to pray, you still gets because there is God.

Yet you never faced problems, you still say because there is God.

Yet you never lied and deceived someone, you still say because of God.

Yet you made a mistake, you still get it corrected and say there is God.

Yes my friends, its true there is God. There is an energy behind everything that moves around us, around others. From the ancient philosophers, scientist to the modern philosophers, scientist goes around and find only one thing in common and that is they say is God.

To God,

From

The Believers. Enjoy and keep smiling. :)

Dragon, Fly – Android v/s iOS

Hello Dear Friends,

I happened to get a chance to play new game called “Dragon, Fly” on one of my friends’ Samsung GS1. I will say it was total addiction. I would like to write some of my views:

Pros:
  • Graphics
  • Smooth
  • Easy to learn
  • Simple settings and good pictorial tutorial
  • Terrain changes on daily basis
  • Swoosh, Sky Fly and Hot Fire modes are quite good mode to encourage the player to earn more points
  • Sound is also good
  • Point system is clear and you can compete globally.
Cons:
  • Memory consuming
  • No Replay option
  • No Story line like we do have in Angry Birds.
Then again luckily i got a chance to play same type of game on iPod Touch and name is Angry Hill“. For that i would like to compare same game on different OS.
Pros:
  • Different types of Terrain i.e. Dark, Light and Bright.
  • Funny graphics for kids.
  • Best free game in iTunes
  • You get a buddy to compete with
  • Also arcade mode is same  version like we have in Android version.
Cons:
  • Needs improvement on Graphics area
  • Sound is not interesting
  • Scaling of screen while high jump is not smooth
  • No story line.
Some video review that i found on YouTube, thanks to these video uploads :
Dragon, Fly

 

Angry Hills

I would like to give rating to both of these games:

Dragon, Fly – 8/10

Angry Hills – 7.5/10

Thanks guys for reading this post and do let me know if you have any comments.

Amarnath Yatra

This video is compilation of the pictures that we clicked when we went to Amarnath in Kashmir, India in 2005. I know so old but memories are still fresh like it happened last year only.

We started our journey from Delhi. Our first stop was at Patnitop, a cool, peaceful hill city and it lies among serene beauty of Himalayan trees. Next day we reached to Balltaal, it was the starting point for the Amarnath yatra of 21 km long. We thought of that various foods and liquid stuffs will be provided during this walking journey, but we found none. We had to eat ice directly from the Glaciers. Anyway somehow we reached to Amarnath cave, and it started raining there, then organizers, army police start vacating that place and said that nobody will stay here in night. All have to go back to the starting point in tents. So we rush towards the cave and after two hours we were ready to go back to down. But suddenly i started wondering where are my shoes, and as usual my shoes were not there. Somehow i found somebody else’s shoes that is fit to my size and we were fully ready by then.

By late midnight we were back to the starting point and just laid down there. under a tree in the blankets that army provided. It was great thrill and adventurous trip that none of us could forget specially me because it was as tough for me to go there and come back.

Hope you all will get the chance to visit that mesmerizing place at least once in your life.

Enjoy.

Photo of Lord Amarnath taken by Mr.Gangadhar T...

Image via Wikipedia

Subcontinent Suffering

I was going through various articles and I was startled by the fact that entire subcontinent is suffering from the war, hatred. Why it is happening to this beautiful subcontinent. When we go back to ancient ages then we got to know that this Hindustan or you can say subcontinent, was not much indulged in the war. Yes there was some wars fought in between Outsiders and Insiders, hatred between the countries but that was happening for those people who wanted to fight or with those who are trained for the fight. But nowadays innocent people are being attacked and they are the centre of all the attacks. Mumbai attack, Delhi attack, Jaipur attack, Bangalore attack related to India.
           This is not enough India is handling with ULFA, LTTE, and NAXALITES also. These groups are not from outside. They are from India and question is are they fighting for India? No they are fighting for themselves. You can say basic difference between them and terrorist that they are fighting for themselves and terrorist are not sure what they are fighting for, some bunch of sick minded people are deteriorating their mind and they’re playing with their mind. Pakistan struggling and suffering from their internal problems. People there not fighting for the country. If I say that they’re also not sure for what they’re fighting then it won’t be that much wrong. Sri Lanka for a long period they’re fighting with LTTE. They are now just want to end this but LTTE doesn’t seem to be stopped.
            Bangladesh fighting with corruption, instead of having a great cultivated land still they not up to the mark to utilize that land, they’re also indulged with the war and internal fight. Nepal now only they’ve come out with the monarchy system but still their power is not in right hand. They need real leader, who can lay a path for them a path to their success. Let’s see what will happen to their future. Afghanistan still suffering with the Taliban, US somehow managed to end the worst era for the Taliban’s, Iraq they were able to conquered, Saddam was already hanged till death by them. But they’re still fighting with the Taliban’s.
          Osama Bin Laden is dead as per US Government but nobody saw the dead body. There also innocent people are under the target. They are being target by terrorist and sick minded people. Whole subcontinent is suffering. Terrorism spreading more and more day by day. People can not live happy, they’ve so much tension to live this life, entire life they spent thinking what is the current price of fuel, rent, money, vegetables and all. A very few people go above this and think about other things, things like how they can contribute to this society, this city, this state and to country.
I am going away from my actual topic. So my question was why this is happening to this sub continent. This Subcontinent consists of INDIA, PAKISTAN, SRI LANKA, BANGLADESH, NEPAL, and AFGHANISTAN.
So if you see every country is suffering from something related to war, attack, terrorism, hatred, internal issues. So why this sub continent is suffering. Is it cursed if I state in terms of superstitions or is it because we are not in developed condition? Earlier when we used to be wealthier than any country in the world, was there any problem? Way back then we were not dependent for anything on anyone. So what happened to our happiness? Who stole that cream of our life, our ultimate happiness?
Because of the greed of power, money we’ve already sold out our cultural values to other. They called us third world countries, but can someone ask them to flip the pages of history and find who we were and how we have become like this. They were the people who even not existed in the world. Nobody knows that a big continent even existed way back 600 years back.
Now the real question why the problems are increasing with every tick of time. In India now the tension is for election, who is going to be the next PM. Many tactics are being developed within the party and with the parties. What will be your price, what do you want in the parliament, which section do you want to lead blah. But they are deviating themselves with the ultimate question How they can change the India. How they can SAVE it? What are they going to improve the position of INDIA in the next few years? China, everyone is saying is a threat to India’s development. Yes you can say that but point is how you can catch China? See we’re lagging far behind of China in every aspect whether you take numbers, area, development, growth. Yes they are growing, and world will go with them, because they’re going to the next power of the world.
In US we have seen the biggest change in their history. A man with the African roots and is now sits on the most powerful seat of the world and moreover he was elected by their people. Why the questions itself say WHY? And answer could be because they wanted to see CHANGE. The wave of change started now by electing Obama they’ve shown to the world that they don’t consider their preconceived decision whom they’re going to elect, they don’t bother who is going to lead them now whether he is black or white. They just want that person who can suggest the change, change in everything, change in their living, People are now really tensed by listening now or than that power of the world is slightly shifting to the east. Now you can say so they don’t want to see at the broader level of vision, the ultimate balance of power. Then I would suggest you to think yourselves if this is the question why would they would’ve elected a person who is not even consider as true American by others. They elected him because of thinking. You know people actually crying when he was declared as the next President of US. You can clearly see that glow, that shine in their eyes. They were pretty clear, they’ve shown the world they want Change.
Now I put this question to all of you, how can you save this Subcontinent? Is there any need of change in leadership as it already happened in the US? So who is going to give that feel of change? Ask yourself, think and answer it?
I urge you to contribute something to this world back.