The Artistic Way of Programming

12 years back, when I started my formal classes in computer science, the first thing I learnt was “data” means “information”. A few days after that, we started conventional programming, where code and data were treated separately. For example, only data can be passed as the functional arguments. It was difficult for me to digest that “code, which is also information, is not treated as data”. I strongly felt that this will increase complexity of softwares in the long run.

A system does three things – read, transform (processing data), write. In other words – the mathematics (the transform part), and the effect of that in real life (the read/write part). The data transformation is indeed a mathematical concept, and with the help of read and write we make the mathematics (the transform part) useful to the real world. Bringing the “transform” part fully inside mathematical domain has its own benefit of using mathematics without fear (possible errors) for the analysis of the system, making the system more tractable mathematically. The catch is to treat both the elements of transformations, data and functions, equally.

Initially, code used to be bigger than the data, so sending data over the wire was feasible. But with time, data becoming huge, sending code to systems over the wire becomes the need, resting the data on the systems intact. With big data, the need of the hour is to treat the code as data, so that the code can be taken as argument to another meta function on a system having huge data which expects an algorithm for transformations.

Roughly speaking, codes are algorithms, algorithms are mathematical functions, functions are in turn actually look-up tables, i.e. data. Hence with this principle, all codes or functions are data.This is exactly the cornerstone of the functional paradigm. The functional programming is programming with functions, they treat functions and data likewise. Another principle I love, to control complexity, rules should not be complex itself.

Thumb rules rewritten for the functional paradigm:

Read-write and transformations(algorithms) should be separate.
Use immutable variables. Discourage use of reassignment statements.
Discourage side-effects (input/output or changing any variable in-place), every function should ONLY return its expected result.
Use referentially transparent functions (sometimes it is called pure functions) with no side effects, i.e. if x = y, f(x) and f(y) should be same forever.
Unit testing is a must for each function.
One of the main design patterns should be followed is to use expressions instead of instructions, i.e. it should be declarative in nature. Discourage use of loops like for/while – use recursive statements as shown above to calculate sum. Tell computers what needs to be done, not how to do it – it reduces error, especially edge cases.
With the need to control the complexity of the system and the advance design, the design pattern for the functional composition can be made to follow some basic algebraic structures, which in turn becomes more robust.

Posted in Uncategorized | Comments Off on The Artistic Way of Programming

Whither the World’s Fair?

The moniker “Expo 2017” is currently being bandied about in North America. In the US, various optimists, often plain vanilla citizens like you and me, have launched web sites and forums promoting a return of the world’s fair–or Expo 2017 in this case–to America. In Canada, at least four cites and/or organizations have recently promoted the idea of an “expo”, with one of the first efforts publicly unveiled in Montreal in 2007.

In America, the idea of a world’s fair–an officially sanctioned one, that is, will conceivably remain a distant dream until Washington comes to its diplomatic senses and rejoins the Bureau of International Expositions, or BIE–the governing body in Paris which awards world’s fairs in much the same fashion as the IOC decides who gets to hold the next Olympic Games. Just like the Olympics, an aspiring world’s fair applicant is required to invest a considerable amount of energy and expense putting together a bid, and, of course, impressing the appropriate officials. Unless, perhaps, you’re the city of New York which, after a clash with French dignitaries, decided to hold its 1964/1965 World’s Fair without BIE approval. At the time, superpower America had enough clout that many of the nations who were subsequently prohibited by the BIE from participating decided to show up anyway, posing as trade and tourist organizations.

Right after New York, and only a skip across the border, the city of Montreal staged what is often considered to be the most successful (and BIE approved) world’s fair of all time. Set on a sprawling venue of two man-made islands and a peninsula in the middle of the Saint Lawrence River, Expo 67 introduced a number of technological and cultural “firsts”–including the now ubiquitous moniker “expo” itself.

There are “expos” for everything now, from computers to kitty litter, while the mighty world’s fair that spawned these cheap imitations hasn’t been seen in North America for decades. Even if a city here managed to secure an official bid for “Expo 2017” it would be for a much smaller affair, a “recognized” expo limited by the BIE to 25 hectares exhibition area. That’s because there have always been two types of world’s fairs, a very large one (a “universal expo”) and, in-between, a smaller one (a “special expo”)–both of which are now, respectively, called “registered” and “recognized” fairs. In 2017, unfortunately, only the smaller recognized expo is allowed.

Nevertheless, I would argue that the world’s fair not only needs a major boost in North America, but that North America desperately needs another world’s fair. No other event has the collective potential to attract a huge audience to the latest cultural and scientific endeavours humankind has to offer. With our planet in the precarious state we have put it in, and North America no longer as influential and respected as it used to be, a world’s fair, properly staged and presented with the latest social and environmental initiatives, could be the political and technological beacon of hope this continent is yearning for. Of course, that might mean that Expo 2017 would need to encompass a great deal more than 25 hectares exhibition area and would need to address a lot more than the narrowly restricted theme (the fair’s purpose) officially allowed by the BIE for a smaller “recognized” expo. This could be done, with a little creative thinking (and without resorting to New York’s 1964 strategy), but that’s for another article to address.

Posted in Uncategorized | Comments Off on Whither the World’s Fair?

Tips For Buying And Maintaining Shoes

Choosing a good pair of shoes and taking good care of it is an art. This article has some basic tips for you to maintain the quality of your favorite shoes. Hopefully, this will help you make your shoes stand the test of time.

1. When buying shoes

When should you try your shoes before buying them? Well, ideally, you should try them in the evening. This is because your feet are slightly bigger in size in the evening. Go to your desired store in the evening, put on the shoes you want to try and then walk around to see how you feel in them.

If you have to move around a lot during the day, we suggest that you go for instant heels as these shoes distribute your weight evenly and you feel comfortable.
2. Posture and gait

What is the right way to walk? Proper gait can make your body appear slimmer, especially if you are a woman. The idea is to keep your feet straight when walking. For each step, you may want to hold a bit long striding. Keep in mind that improper gait and posture will make you feel less comfortable while walking and it may also make your shoes wear and tear faster. Usually, the biggest reason why people don’t feel comfortable while walking is that the shoes are not the right fit for them.

3. Cleaning the shoes

For wiping stains from your leather shoes, you can use banana peels. Actually, banana peels contain certain ingredients that make it easier for you to remove stains from your shoes. On the other side, you can also go for milk to wipe the surface of the shoes.

Another good cleaning agent is vinegar. It will clean your shoes and make them shine. The great thing about vinegar is that it is better than most of traditional cleaning methods.

4. Leather shoes Upkeep

Shoes made from leather tend to get stiff. In order to soften leather shoes, you can opt for a quality absorbent pad. However, keep in mind that this method should be used occasionally as the regular use may reduce the life of your shoes.

If your leather shoes are stiff, you can cut a potato in half and dip it in the lemon juice and then clean the surface of the shoes with it. Keep in mind that placing the shoes near fire is not recommended after the application of the cleaning method.
5. Drying Wet Shoes

If your shoes get wet, lime powder is a good agent to dry them out. Lime power will also give your shoes a sweet smell. For fur shoes, you can try a dryer, and this is an ideal method for drying shoes in winter.

So, these are a few tips that you can use to buy shoes pair of shoes and then take care of them so that they will stand the test of time. Keep in mind that buying expensive shoes is not a big deal. The big deal is to take care of their maintenance and make them last longer.

Posted in Uncategorized | Comments Off on Tips For Buying And Maintaining Shoes

Private Jet Detailing And Aircraft Cleaning Entrepreneurs Have Good News

The general aviation sector has been in the doldrums for quite a while. Some blame this on increased FAA (Federal Aviation Administration) regulations, much of which occurred after 9-11 to protect airports from potential terrorists, unfortunately these increased security requirements and increased regulations have stifled the general aviation (GA) sector. The economic crashes of 2000 and 2008 didn’t help, although in 2003 the economy was flying high thanks to Bush Tax Cuts and stimulus, then it hit a wall again and didn’t really do well until the run-up just before the 2008 crash.

The GA sector has only slightly recovered since then but not back to its 2003 highs. When Obama got elected he railed against Corporate Jets and Corporate Fat Cats which hurt jet sales and new aircraft sales. Remember when congress went after the Auto Makers for flying their corporate jets to Washington DC to beg for bailouts? Public sentiment against GA was at an all-time low. All of this had hurt aircraft cleaners and jet detailers – it made it tough to make money, but it looks like things are changing and the number of GA Aircraft is increasing. This new Trump Administration is pro-Aviation unlike the Obama Administration. Cutting corporate taxes will also help GA and jet sales. It looks like clear skies ahead for those in the General Aviation services business.

There was a great article in AIN – Aircraft International News – December Edition titled; “UBS Bizjet Index Sees Post-election Surge,” by Chad Trautvetter posted on December 12, 2016 which noted the following facts; The new Trump Administration in the U.S. is widely seen as a positive, with 61 percent of those surveyed expecting the outcome of the U.S. presidential election to ultimately be positive for the business jet market, while 11 percent don’t see a positive impact and 28 percent are uncertain. In fact the article went on to note that there was an increase of between 44-49% increased orders for private jets over last year. Many of those aircraft will be delivered by 2018, and the backlog will increase used aircraft sales and current new inventory. More aircraft certainly means more aircraft to clean and more new aircraft means more corporate detailing customers as well. Meanwhile, along with the fractional jet market, we see jet air-taxi services on the increase as well as Uber style aircraft ride-sharing plans smaller companies can buy into. All of this means the GA sector is ready to take off again and that’s good for business.

Posted in Uncategorized | Comments Off on Private Jet Detailing And Aircraft Cleaning Entrepreneurs Have Good News

The Last Chance for Gold

Growing up in my corner of Florida, there used to be an old gas station on the edge of the Everglades. The proprietor did a lot of business with his oversized, hand-painted warning sign:

Last Chance for Gas.

Beyond the fuel pumps were a thin two-lane ribbon of asphalt and 90 miles of swampy wilderness. No smartphones. No “emergency call boxes.” And, in most places along the highway, no guardrails either.

You were on your own – much like the economic wilderness we’re all forced to navigate today.

Which is why the sharp decline in gold prices and mining stocks is much like that warning sign… and a monetary gift…

In short, if you were waiting on the sidelines after this year’s monster rally, this is your second chance – and, in my view, your last chance – to buy gold at these prices. And it comes at just the right time. Typical Moves for Gold

Gold’s done a full round trip in buyer sentiment during the past 12 months: from being the world’s “most hated commodity” at its lows near $1,050 an ounce 12 months ago to “gotta buy it” status at $1,350 an ounce this summer.

With gold now fallen from those lofty heights, an investor is more likely to ask: “Gold, what have you done for me lately?”

In all, gold’s given back about 60% of its 2017 rally. Yet such sharp declines followed by a resumption of a broader trend higher is a typical early bull market move for this volatile metal. Most famous of these pullbacks was gold’s run to all-time highs in the 1970s.

Starting out at $35 an ounce in the early ’70s, as gold became legal for Americans to own once again, bullion prices soared to almost $190 an ounce in 1975. That’s quite a run all on its own. During the next 18 months, gold prices dropped back nearly 60%, falling to $100 before running to a then-record $800 an ounce in the next three and a half years.

The Song Remains the Same

Most important, when it comes to the companies that dig this stuff out of the ground… nothing has changed.

As I have pointed out in past months, gold mining firms have done a great job getting their costs down and making money to boot.

We noted as early as February that the elite companies in this group were making an average of $215 for every ounce of gold they were digging out of the ground and said, in no uncertain terms, to anyone who’d listen: “Stop panic selling gold mining stocks. Likewise, after cutting dividends in 2014 and 2015 as gold prices plummeted, many of the same companies have not only reinstituted payouts, they’ve started raising them again. In the meantime, mining firms have cleared away much of their old cost structures. That’s why Newmont Mining, as one example, has been able to drop its “AISC” – all-in sustaining costs – from $1,170 in 2012 to $910 so far in 2016.

The point is that there are many reasons to own gold: for speculative profits, as discussed above; for insurance; and for wealth preservation. But you can’t benefit from any of those strategies without taking advantage of the gift that is low gold prices and low expectations put on our table by Wall Street’s hair-trigger traders.

Posted in Uncategorized | Comments Off on The Last Chance for Gold