Even Flies say grace…

A funny picture I received but it made me think how in modern times, one can get super busy and forget to say grace before eating. This is especially true if you live alone and away from your family who taught you and enforced those values when you were a kid.

You know what? Even robots say grace! 🙂

You might also like:

HTMLPen – Free Online HTML authoring tool

HTMLPen is the most advanced online Visual HTML Editor and Text Editor available.

Some HTML features are :

  • Free Visual WYSIWYG Editor
  • Instant Previews and JS Previews
  • Advanced HTMLCSS and JS Color Coding and Code Completion.
  • Embedded HTML, CSS and JavaScript Beautifier.
  • Advanced Color Picker with Alpha Channel
  • Embedded Image to Base64 Converter
  • Respects your Privacy. No data ever leaves your computer
  • Stores your open projects on browser LocalStorage so you can keep working on them later

HTMLPen is also a powerful online Text Editor and Code Editor that can identify 144 different languages.

  • Syntax Highlighting
  • Code Completion
  • Can open Very Large (TB+) Files
  • Regex Search and Count Functions
  • Respects your Privacy. No data ever leaves your computer

HTMLPen can recognize many languages, including:

ABAP, ABC, ActionScript, ADA, Apache Conf, AsciiDoc, Assembly x86, AutoHotKey, BatchFile, Bro, C and C++, C#, C9 Search Results, Cirru, Clojure, Cobol, CoffeeScript, ColdFusion, Csound, Csound Document, Csound Score, CSS, Curly, D, Dart, Diff, Django, Dockerfile, Dot, Drools, Edifact, Eiffel, EJS, Elixir, Elm, Erlang, Forth, Fortran, FreeMarker, Gcode, Gherkin, Gitignore, Glsl, Go, Gobstones, GraphQLSchema, Groovy, HAML, Handlebars, Haskell, Haskell Cabal, haXe, Hjson, HTML, HTML (Elixir), HTML (Ruby), INI, Io, Jack, Jade, JavaJavaScriptJSON, JSONiq, JSP, JSSM, JSX, Julia, Kotlin, LaTeX, LESS, Liquid, Lisp, LiveScript, LogiQL, LSL, Lua, LuaPage, Lucene, Makefile, Markdown, Mask, MATLAB, Maze, MEL, MIXAL, MUSHCode, MySQL, Nix, Nix, NSIS, Objective-C, OCaml, Pascal, Perl, pgSQL, PHP, Pig, Powershell, Praat, Prolog, Properties, Protobuf, Python, R, Razor, RDoc, Red, RHTML, RST, Ruby, Rust, SASS, SCAD, Scala, Scheme, SCSS, SH, SJS, Smarty, snippets, Soy Template, Space, SQL, SQLServer, Stylus, SVG, Swift, Tcl, Tex, Textile, Toml, TSX, Twig, Typescript, Vala, VBScript, Velocity, Verilog, VHDL, Wollok, XML, XQuery, YAML

Made in sunny California.

HTMLPen.com 2018

You might also like:

Before you speak, let your words pass through three gates

I found this nice picture on the Internet:

I found it very inspiring and serves as a reminder to improve myself when I am engaging with others.

Basically, before saying anything to others, one should be mindful of the effects of their words. Words are very strong and are even said to be stronger than swords and weapons.

Before speaking, ask yourself three questions: Continue reading “Before you speak, let your words pass through three gates”

Batchography: Autorun a Batch file script each time you open the command prompt

This is yet another short article from the many topics mentioned in the Batchography book. In this article, I am going to show you how to have a Batch file of your choice execute each time you open the command prompt.

Putting it simply, all you have to do is create a string registry value called AutoRun under HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Command then specify the path of the Batch script you want to run!

A useful AutoRun Batch script is a script that sets up command macros using the Doskey command, but that’s a topic for another time!
flower separator
Buy from Amazon:

The A-B-C-D Model – Cognitive Behavioral Therapy

I am not a psychologist, but recently I learned about an interesting tool that can help one enhance their cognitive behavior. It is called the “A-B-C-D Model” or simply the “ABC cognitive model”.

It is developed by one of the Cognitive Behavioral Therapy (CBT) founders: Albert Ellis, PhD. This model can help one think and act more rationally, thus lead a stress free life.

The moment I learned about this model and understood how to apply it, it became an important tool in my daily life. Continue reading “The A-B-C-D Model – Cognitive Behavioral Therapy”

Today’s Reality…Sad but true…

Sometimes, chain emails are educative. This time, the video talks about the today’s reality with respect to friendship, love, health:

Please watch the video and feel free to share it with others:


You might also like:

It’s a dog eat dog world

I come from Lebanon and the dog eat dog mentality is what I have experienced all my life.

I don’t know why, but for some reason I was different than others. I never liked or participated in the dog eat dog mentality. I was always honest even though people would most often take my  fair share of things because of that. Eventually, as life wished it, I managed to leave Lebanon and live in a better country that is not rampant with cheating, bribing and corruption.

In my home country, politicians and people in power steal from the poor instead of helping them. The whole country is ran like a family business where the politicians pass the chairs down from father to son.

Due to scarcity, even the people started to adopt the mentality: “Me first, others later”. Eventually, they started cheating on each others. A famous song by Ghassan El Rahbani (in Arabic), describing the whole situation in Lebanon. Lebanon is not unique in that aspect. Probably other third world countries thrive with this mentality as well. Continue reading “It’s a dog eat dog world”

How to prepare yourself before traveling from the US to Belgium

Belgium is a beautiful country. It was my second home for a while, I lived there for 3 beautiful years after I moved from Lebanon. I moved out of Belgium almost 6 years ago to start living in the U.S.A. Last month, I had to go to Belgium for work and it seems I was not fully prepared for the trip.

This post is not to complain about anything but to remind myself or others how to be best prepared before traveling from the US to Belgium.

You can keep the tips…to yourself

Yes, unlike the U.S, you pay exactly for the item price on the menu. You don’t have to tip anyone for the rendered service. I am not just talking about not tipping when you are eating out in restaurants; even your barista, cab driver, your hair dresser, your apartment cleaner, etc. Keep the tips to yourself or tip up to your discretion. That’s a positive thing in my opinion because those workers are getting a proper salary and not waiting for tips from clients.
In the US, you are expected to tip 20% of the total bill. Often times, when a party of 5 or more are being served then mandatory gratuity is applied. It can get very tricky and passive aggressive when you don’t like the service and you don’t tip enough. That sucks and is unfair towards the workers. I think the tipping mentality stems from the fact that it incentivises service workers to provide good service. If they do well, they get a fat tip. Well, if you are generous and happy you can still tip a Belgian waiter on top of his proper salary. Continue reading “How to prepare yourself before traveling from the US to Belgium”

Batchography: Arithmetic operations in Batch files

Did you know that you can do basic arithmetic operations in a Batch file script?

The syntax is simple:

set /A result=EXPR

For example, to add 10 and 20:

@echo off
set /p result=10+20
echo result=%result%

From the “SET /?” output, these are the supported arithmetic operations:

The /A switch specifies that the string to the right of the equal sign
is a numerical expression that is evaluated.  The expression evaluator
is pretty simple and supports the following operations, in decreasing
order of precedence:

    ()                  - grouping
    ! ~ -               - unary operators
    * / %               - arithmetic operators
    + -                 - arithmetic operators
    << >>               - logical shift
    &                   - bitwise and
    ^                   - bitwise exclusive or
    |                   - bitwise or
    = *= /= %= += -=    - assignment
      &= ^= |= <<= >>=
    ,                   - expression separator

Now, let’s make a simple interactive calculator:

@echo off
:main
  setlocal
  set /p num1=Enter first number:
  set /p op=Enter operator:
  set /p num2=Enter second number:

  set /a result=%num1% %op% %num2%

  echo Result is %result%

  endlocal

  goto :eof

When we enter: 4, * then 5, we get the following output:

Enter first number:4
Enter operator:*
Enter second number:5
Result is 20

The Batchography book covers this topic in details and more. Check it out!

You might also like:

Batchography: Function calls in Batch file scripts

The Batch files programming language is a powerful language but unfortunately, not many people know it that well. In an effort to pass the knowledge, in this article I am going to illustrate how to do function calls in Batch scripts.

Let’s get started!

The basics

The following example illustrates how to define and call a function:

@echo off
:main
  call :hello
  call :world
  goto :eof

:hello
  echo This is the Hello function
  goto :eof

:world
  echo This is a second function call
  goto :eof

The following outputs:

This is the Hello function
This is a second function call

From the example above, it is obvious how to call a function and return from it:

  1. Define a function as you would define a label
  2. Use the “CALL :function-name” syntax to call the function
  3. Use the “GOTO :EOF” to return from the function back to the caller

Recursive functions are also supported in the Batch language. Just make sure you avoid infinite recursion. Continue reading “Batchography: Function calls in Batch file scripts”

37 Sayings

  1. The first victim of war is the truth
  2. Don’t treat people like angels, you will become a fool. Don’t treat people like devils for they will think you are the devil. Instead, treat people like they have some angelic traits and a lot of demonic traits
  3. Giving, even a little is better than an empty promise
  4. One cannot be judged by his outfit but from his actions
  5. He who takes refuge under a big tree always finds himself in the shadow
  6. He who does not like to get wet cannot go fishing
  7. When we die, the only thing we take with us is our good deeds
  8. When faced with a task: treat an easy task as hard one and a hard task an easy one
  9. The flower that gets smelled by many loses its scent
  10. When the love for oneself increases, the love from others decreases
  11. Only those who never experienced pain mock others
  12. A tongue has no bones but it can break bones
  13. A man can fail over and over again but it won’t count as failure until he starts blaming others
  14. The computer looks a lot like the Old Testament, lots of rules and no mercy
  15. The law is made for the rich but enforced on the poor
  16. Choose your wife with an old man’s mentality. Choose your horse with a young lad’s mentality
  17. Three kinds of people start wars: the cowards, the egoists or devious women
  18. A single flower given to a living human is better than a bouquet of flowers
  19. Don’t let your expensive cloth define you lest you find yourself one day cheaper than what you desire
  20. The more I know, the more I realize how ignorant I am
  21. A ferocious tiger in front of you is better than a treacherous wolf behind your back
  22. If a word is spoken through the heart, it goes to the heart. If it is spoken through the tongue it won’t go further than the ears
  23. He who looks at his shortcomings, forgets to look at other people’s shortcomings
  24. True philosophy is when we reconsider our view of the world
  25. If you preach your brother in private then you have benefited him. If you preach him in public, you humiliate him
  26. A golden saddle does not make a donkey a horse
  27. War is nasty, but what is nastier is those who make wealth and benefit of it without even fighting the war
  28. Eat less and live long
  29. Morning work is the most productive
  30. The prince picks the fruit and the workers pick the tree
  31. For the hard worker, a week is 7 days, for the lazy it is 7 tomorrows
  32. Nothing can scratch your back like your own finger nails
  33. Three enter all homes, no exception: debt, old age and death
  34. Don’t say “I will give”, instead give
  35. Three things lead to love: good manners, humility and being religious
  36. Good reputation is like an olive tree, it does not grow fast but it lasts long
  37. The tongue of the wise is behind his heart and the heart of the reckless if behind his tongue

You might also like: