Category Archives: Blog-3

Transpiler

 Transpilers, or source-to-source compilers, are tools that read source code written in one programming language and generate equivalent code in another language with a similar level of abstraction. A good example of a translator is the TypeScript translator, which translates TypeScript code into JavaScript. The Babel compiler can also be used for ES6 JS code to ES5 JS code.

Compilers also translate code from one language to another, but the level of abstraction is very different between the two languages. For example, compile from .java to .class files.

ES6 and ES5

To understand the translator, you must first understand the difference between ES6 and ES5 JavaScript. ES6 (ECMAScript 6) is the specification for the next version of JavaScript. Some of its major enhancements include modules, class declarations, lexical block scopes, iterators and generators, a commitment to asynchronous programming, deconstructing patterns, and appropriate tail calls.

The features are great, but most browsers do not support the specification until now. As a result, any UI application specification written in ES6 will not work in most browsers. To run these applications, you must convert this ES6 source code to the supported JavaScript version ES5. ES5 is supported by almost all browsers and is by far the most stable version.

ES6 – Brings “types” to JavaScript. Make it closer to strongly typed languages such as Java and C#. So far, most browsers don’t support it. It must be converted to ES5 to execute in the browser.

ES5 – Over the years, we’ve been writing plain JavaScript.

Translation unit

A compiler is a program-like compiler that converts ES6 JavaScript code into ES5 JavaScript code to run in a browser. When the compiler sees an expression that uses the language functionality that needs to be translated, it generates a logically equivalent expression. The resulting expression can be very similar to or very different from the source expression.

What does a translator do?

ES6 code => ES5 code (even ES4, ES3)

Sources

https://scotch.io/tutorials/javascript-transpilers-what-they-are-why-we-need-them

https://devopedia.org/transpiler

From the blog haorusong by Unknown and used with permission of the author. All other rights reserved by the author.

Transpiler

 Transpilers, or source-to-source compilers, are tools that read source code written in one programming language and generate equivalent code in another language with a similar level of abstraction. A good example of a translator is the TypeScript translator, which translates TypeScript code into JavaScript. The Babel compiler can also be used for ES6 JS code to ES5 JS code.

Compilers also translate code from one language to another, but the level of abstraction is very different between the two languages. For example, compile from .java to .class files.

ES6 and ES5

To understand the translator, you must first understand the difference between ES6 and ES5 JavaScript. ES6 (ECMAScript 6) is the specification for the next version of JavaScript. Some of its major enhancements include modules, class declarations, lexical block scopes, iterators and generators, a commitment to asynchronous programming, deconstructing patterns, and appropriate tail calls.

The features are great, but most browsers do not support the specification until now. As a result, any UI application specification written in ES6 will not work in most browsers. To run these applications, you must convert this ES6 source code to the supported JavaScript version ES5. ES5 is supported by almost all browsers and is by far the most stable version.

ES6 – Brings “types” to JavaScript. Make it closer to strongly typed languages such as Java and C#. So far, most browsers don’t support it. It must be converted to ES5 to execute in the browser.

ES5 – Over the years, we’ve been writing plain JavaScript.

Translation unit

A compiler is a program-like compiler that converts ES6 JavaScript code into ES5 JavaScript code to run in a browser. When the compiler sees an expression that uses the language functionality that needs to be translated, it generates a logically equivalent expression. The resulting expression can be very similar to or very different from the source expression.

What does a translator do?

ES6 code => ES5 code (even ES4, ES3)

Sources

https://scotch.io/tutorials/javascript-transpilers-what-they-are-why-we-need-them

https://devopedia.org/transpiler

From the blog haorusong by Unknown and used with permission of the author. All other rights reserved by the author.

Boundary Value Analysis and Equivalence Partitioning Testing

When it comes to a large pool of input data, it is not possible to perform exhausting testing for each set of test data. There should be an easy way to select test cases from the pool so that all scenarios are covered. This is when the Equivalence Partitioning & Boundary Value Analysis testing techniques were introduced. In today’s blog, I want to do further research on the testing technique of Boundary Value Analysis and Equivalence Partitioning Testing. Equivalence Partitioning and Boundary value analysis are linked to each other and can be used together at all levels of software testing. To start, Boundary value testing is the process of testing between extreme boundaries between the partitions, for example like start, end, lower, upper, maximum, minimum, just inside, and outside values. Normally Boundary value analysis is part of stress and negative testing. Using the Boundary Value Analysis technique tester creates test cases for the required input field.

Now when it comes to equivalence partitioning or equivalence class testing is a type of black box testing technique in which the input data units are divided into equivalent partitions that can be used to derive test cases. This helps with reducing the time required for testing a small number of test cases. This technique can be applied to all levels of software testing like system, unit, and integration. One of the examples that were widely used in many resources that I have look at is: let us say a password field accepts a minimum of 6 characters and a maximum of 10 characters, that means results for values in partitions 0-5, 6-10, 11-14 should be equivalent.  The three testing scenarios will be:

1       Enter 0 to 5 characters         System should not accept

2       Enter 6 to 10 characters       System should accept

3       Enter 11-to-14-character      System should not accept.

Equally, Both testing techniques are used to reduce a very large number of test cases to a manageable piece, Both are appropriate for calculating intensive applications with such a large number of variables and input data.

https://www.guru99.com/equivalence-partitioning-boundary-value-analysis.html

https://www.softwaretestingclass.com/boundary-value-analysis-and-equivalence-class-partitioning-with-simple-example/

From the blog Derin's CS Journey by and used with permission of the author. All other rights reserved by the author.

Expose your ignorance AND confront your ignorance

If you want to reassure them, it should also be through your ability to learn, not by pretending to know what you don’t. In this way, your reputation will be based on your ability to learn, not on what you already know. The easiest way to expose ignorance is to ask questions.

People often disguise their ignorance by pretending to know a great deal about their field. But they forget that knowledge is acquired by knowing one’s own ignorance. Knowing your ignorance, and then study hard to improve your knowledge reserve, is a craftsman needs to have and cultivate the basic quality. Because no one can know all the knowledge in their field, it is through their own ignorance and facing their own ignorance that you can truly achieve the omniscience you need to achieve. It takes a certain amount of courage to recognize and face your ignorance correctly. But in the show you will find that often standing on top of the people they will be very open to accepting their own ignorance, and open to learning. Often it is the people who are afraid to face their ignorance that have little knowledge of their own territory.

Pick a skill, tool, or technique and actively fill in the knowledge gaps associated with it. Do it in the way that works best for you. For some, the best approach may be to read all the literature and FAQs available to get an overview. Others may feel that building a “crunchy toy” is the most effective way to understand something. Whichever method works for you, don’t forget to ask around with your “peers” and mentors to see if anyone has already mastered the skill and is willing to share what they’ve learned. Sometimes others may be learning the skill, and you’ll progress faster by working with them. At some point, you will have reached a satisfactory level of competence in this new area, and you can decide whether it is more productive to dig deeper or to turn your attention to other skill gaps. With only 24 hours in a day, you can’t grind every skill to a very high level, so you have to learn to make the necessary tradeoffs between them.

It’s not just about conquering previously unknown peaks, it’s about carving out a new path, step by step.

From the blog haorusong by Unknown and used with permission of the author. All other rights reserved by the author.

Expose your ignorance AND confront your ignorance

If you want to reassure them, it should also be through your ability to learn, not by pretending to know what you don’t. In this way, your reputation will be based on your ability to learn, not on what you already know. The easiest way to expose ignorance is to ask questions.

People often disguise their ignorance by pretending to know a great deal about their field. But they forget that knowledge is acquired by knowing one’s own ignorance. Knowing your ignorance, and then study hard to improve your knowledge reserve, is a craftsman needs to have and cultivate the basic quality. Because no one can know all the knowledge in their field, it is through their own ignorance and facing their own ignorance that you can truly achieve the omniscience you need to achieve. It takes a certain amount of courage to recognize and face your ignorance correctly. But in the show you will find that often standing on top of the people they will be very open to accepting their own ignorance, and open to learning. Often it is the people who are afraid to face their ignorance that have little knowledge of their own territory.

Pick a skill, tool, or technique and actively fill in the knowledge gaps associated with it. Do it in the way that works best for you. For some, the best approach may be to read all the literature and FAQs available to get an overview. Others may feel that building a “crunchy toy” is the most effective way to understand something. Whichever method works for you, don’t forget to ask around with your “peers” and mentors to see if anyone has already mastered the skill and is willing to share what they’ve learned. Sometimes others may be learning the skill, and you’ll progress faster by working with them. At some point, you will have reached a satisfactory level of competence in this new area, and you can decide whether it is more productive to dig deeper or to turn your attention to other skill gaps. With only 24 hours in a day, you can’t grind every skill to a very high level, so you have to learn to make the necessary tradeoffs between them.

It’s not just about conquering previously unknown peaks, it’s about carving out a new path, step by step.

From the blog haorusong by Unknown and used with permission of the author. All other rights reserved by the author.