teleren/devto huggingface dataset:
TDD Conference 2021 - Why You Might Not Want To Use TDD? - Ola Kunysz
Tags: tdd, programming, testing, codenewbie
Published: 2021-07-25 03:05:35

First International Test Driven Development took place on July 10th. 

In this series, I will include every talk together with my notes and further reading.

Hopefully, a lot of readers will watch and rewatch the talks, as they are worth several reviews.

Let's continue...

## Bio 

Ola Kunysz is a software engineer with 14 years of experience. Besides coding, she has experience in business analysis and consulting. Since 2019 she runs her own company, educating programmers about software quality. She speaks at conferences, writes articles and produces online courses. Her biggest interest is solving real-life problems and writing code that matters. For 2 years, she organized meetups and workshops of Geek Girls Carrots in Wrocław, Poland. She enjoys meeting people and working on interesting projects, so you can spot her on hackathons and conferences. When it’s time to relax, she’s offline [with dog (s), playing board games, in the mountains]
 
> TL;DR: TDD can be hard to start and level up, but it is worth it!

## Talk

{% youtube K-tDuE2tN0c %}

# My Personal notes

- TDD is a life-changing technique.
- TDD changes the way you code. It is more declarative and simple.
- We need to introduce very simple baby steps.
- You come back to requirements all the time.
- Simple doesn't mean is easy.
- We don't feel comfortable with the red color.
- Also, green tests are sometimes false negatives. We don't know if everything is working, or we made them wrong.
- Tests are our friends, not our enemies.
- TDD is especially hard and challenging for senior developers, since they have bad habits.
- Mastering new skills is easier for juniors.
- We should learn TDD by watching live coding, not only by reading books.
- It is hard to follow the simple process. Steps are so small we tend to skip them.
- We tend to skip baby steps and move ahead with the already known solution.
- We don't see TDD benefits early. Sometimes you need days or weeks to see the whole picture. Some people give up too early.
- We need to stay humble and follow the process.
- TDD is hard to start or level up to real large projects.
- We should never force people to use TDD.
- We must practice with [Katas](http://codingdojo.org/kata) to move to larger projects.
- Always follow the process without early judging.

> Programmers don't write to check anything. They just test to prove they are right.

# Speaker Links

- Twitter [@olaqnysz](https://twitter.com/olaqnysz) 
- LinkedIn [@akunysz](https://www.linkedin.com/in/akunysz/)
- DevTo @olaqnysz 
- Site [https://socialshub.net/OlaKunysz](https://socialshub.net/OlaKunysz)
- Medium [https://medium.com/@OlaQnysz/](https://medium.com/@OlaQnysz/)

# Talk source 

{% post https://dev.to/olaqnysz/why-you-might-not-want-to-use-tdd-26jf %}

* * *

Please follow TDD Conference on:

- [YouTube](https://www.youtube.com/channel/UCKn-DadPoyYssfAOMk1LSew)
- [Twitter](https://twitter.com/tddconf)
What is the Virtual DOM?
Tags: react
Published: 2021-07-25 02:12:11

The Virtual DOM (VDOM) is an in-memory representation of Real DOM. The representation of a UI is kept in memory and synced with the "real" DOM. It's a step that happens between the render function being called and the displaying of elements on the screen. This entire process is called reconciliation.

[Follow me here](https://www.linkedin.com/in/utsho-sadhak-joy-a79b971ba/)
Commands in SQL
Published: 2021-07-25 02:03:53

If you are planning to one day work with and manage data, chances are, you will eventually have to work with SQL (Structured Query Language). SQL is a language used to communicate with databases, most often used to update data or retrieve specific parts or groups in the data. If any task involves manipulating or creating a database, SQL will work well.

In a previous post, I went over common SQL clauses, most specifically, those used to pull data from databases. In this post, I will go over some commands that are more relevant when creating or modifying a database.

### Common Commands
**CREATE DATABASE** - makes a new database
**CREATE TABLE** - makes a new  table; databases are, in essence, a collection of tables
**UPDATE** - changes or updates data
**INSERT INTO** - inserts new data
**DELETE** - deletes selected data
**DROP** - deletes tables/databases
**SELECT** - indicates what you want to pull from the data (also covered in a previous post)

Here are some important distinctions to make note of. Databases and tables are both collections of data, but a database is a collection of tables. DROP and DELETE differ as DELETE is used on specific data while DROP refers to whole tables or databases. SELECT allows you to pull specific features of the data, but doesn't really manipulate it like the other commands listed.
Julia ❤ Python
Tags: ffi, julia, python, codereuse
Published: 2021-07-25 01:08:08

If you have read my earlier posts you know I love multilingual programming. One important part of multilingual programming is how to interface one language with other. Typically this is called FFI or [foreign function interface](https://en.wikipedia.org/wiki/Foreign_function_interface). At the lowest level often there are libraries (aka bindings) to talk across languages or across implementations of same language e.g. [libffi](https://github.com/libffi/libffi). In my undergrad we did a [group project](https://github.com/vmiheer/leviosa) where we created language bindings to separate algorithmic part written in python and opencv and X11 logic in c.

Recently I have started learning [Julia](https://julialang.org/) which promises programmer productivity of [Python](https://www.python.org/) and performance of [C*](https://en.wikipedia.org/wiki/C_(programming_language)). Julia [PyCall](https://github.com/JuliaPy/PyCall.jl) library provides FFI for Python. After multiple unsuccessful attempts to use PyCall on Windows, I found out one needs to set `PYTHONPATH` environment variable in addition to `PYTHON` environment variable in Julia script to use specific python virtual environment. PyCall can automatically install conda and packages from conda but seems like if one wishes to use virtualenvironment and pip one needs to set these environment variables manually in the Julia script.

```julia
ENV["PYTHON"] = raw"<pathToVirtualEnv>\Scripts\python.exe"
ENV["PYTHON"] = raw"<pathToVirtualEnv>\lib\site-packages"
# Note the `raw` string literal in Julia which eliminates
# need of escaping `\` in Windows paths.
```

Hope you find it useful.
✌
How to move a directory to another folder or directory in Linux?
Tags: resource
Published: 2021-07-25 00:00:00

---
  title: How to move a directory to another folder or directory in Linux?
  published: true
  tags: Resource
  date: Sun Jul 25 2021 05:30:00 GMT+0530 (India Standard Time)
  canonical_url: https://melvingeorge.me/blog/move-a-directory-to-another-folder-or-directory-linux
  cover_image: https://melvingeorge.me/_next/static/images/main-8eacf5cdedc07b6e7d4d86e14d5f180e.jpg
  ---
  [Originally posted here!](https://melvingeorge.me/blog/move-a-directory-to-another-folder-or-directory-linux)
  
To move a directory to another folder or directory, we can use the `mv` command followed by the source path of the directory and then the destination path in Linux.

For example, let's say we have a directory called `directory1` with some files inside it which we need to move to a directory called `directory2`, to do that we can use the `mv` Linux command like this,

```bash
# Move "directory1" to "directory2" directory
mv directory1 directory2
```

- In the above command after the `mv` command we have defined the source path of the directory which is `directory1` and after that the destination path which is `directory2` directory where it needs to be moved to.

- Executing the above command will move the `directory1` directory to the `directory2` folder.

See the execution of the above command live in [repl.it](https://replit.com/@melvin2016/move-a-directory-to-another-directory-in-linux#main.sh).

That's all 😃!

### Feel free to share if you found this useful 😃.

---
Learning tacit knowledge is hard
Tags: tacitknowledge, explicitknowledge, teaching, coaching
Published: 2021-07-26 13:10:17

---
title: Learning tacit knowledge is hard
published: true
date: 2021-07-25 00:00:00 UTC
tags: tacitknowledge,explicitknowledge,teaching,coaching
canonical_url: https://jhall.io/archive/2021/07/25/learning-tacit-knowledge-is-hard/
---

[Yesterday](https://jhall.io/archive/2021/07/24/tacit-knowledge-vs-explicit-knowledge/) I introduced the idea of two types of knowledge: Explicit (that which is easily explained) and tacit (that which is not easily explained). With this model in mind, we logically have four basic ways of transfering knowledge between people:

- **Tacit to tacit** : Teaching someone to dance through demonstration and dancing together.
- **Explicit to explicit** : Teaching someone the steps in a coreographed routine.
- **Tacit to explicit** : Uncovering principles such as rhythm, balance, and momentum, so that they can be explained as descrete pieces of knowledge.
- **Explicit to tacit** : Practicing dance steps to the point that they become habitual and feel like second nature.

Which of these is hardest?

In my estimation, it’s the “tacit to explicit” that’s the hardest.

It’s for this type of knowledge transfer that we’re most likely to hire a coach. Want to improve your golf swing? You might hire a golf coach who watches exactly what you’re doing to discover what tacit knowledge you have (your “bad habits”), and convert them into explicit knowledge so they can be corrected.

It’s no different in business. This is a big reason we hire business coaches: To uncover our tacit “bad habits”. The things we, as individuals and organizations, do blindly, by habit, without realizing it. Until this tacit knowledge can be converted to explicit knowledge, it’s almost impossible (except by sheer luck) to begin to improve.

* * *

If your team is struggling to implement DevOps, I’m here to help uncover your bad habits so you can begin to change. [Contact me](https://jhall.io/contact/) to start the discussion!

* * *
_If you enjoyed this message, [subscribe](https://jhall.io/daily) to <u>The Daily Commit</u> to get future messages to your inbox._
5 Helpful Python Random Module Methods
Tags: python, beginners, tutorial, codenewbie
Published: 2021-07-24 23:29:58

Hello, I'm [Aya Bouchiha](https://t.me/AyaBouchiha), today, I'm going to share with you 5 useful & helpful methods from a random module.

Firstly, we need to know that the Random module is built-in in python for helping you to create random numbers.

## random()

**random()**: returns a random float n where `0 <= n < 1`

```python
import random

print(random.random()) # 0.7291047713945417
```

## randint()

**randint(a, b)**: returns a random integer between the given range. `a <= n <= b`

```python
import random

print(random.randint(1,  10)) # 7
print(random.randint(-12, 2)) # -10
```

## uniform()

**uniform(a, b)**: returns a random float between the given range. `a <= n <= b`

```python
import random

print(random.uniform(5.7, 12)) # 10.096664083501162
print(random.uniform(10, 100.2)) # 95.00994365426938
```

## shuffle()

**shuffle(sequence, func = random.random)**: this method shuffle the giving sequence.In addition, It updates the giving sequence and does not return a new one.

```python
import random

users = ['aya', 'simon', 'john']
random.shuffle(users)
print(users) # ['john', 'aya', 'simon']
```

## choice()

**choice(sequence)**: returns a random element from the giving sequence.

```python
import random

users = ['aya', 'john', 'simon', 'kyle']
winner = random.choice(users)
print(winner) # aya :)
```

### Summary

+ **random()**: returns a random float n where `0 <= n < 1`.
+ **randint(a, b)**: returns a random integer between the given range. `a <= n <= b`.
+ **uniform(a, b)**: returns a random float between the given range. `a <= n <= b`.
+ **shuffle(sequence, func = random.random)**: this method shuffle the giving sequence.
+ **choice(sequence)**: returns a random element from the giving sequence.

## References & useful Ressources

+ [https://docs.python.org/3/library/random.html](https://docs.python.org/3/library/random.html)
+ [https://www.w3schools.com/python/ref_random_choice.asp](https://www.w3schools.com/python/ref_random_choice.asp)
+ [https://www.youtube.com/watch?v=KzqSDvzOFNA](https://www.youtube.com/watch?v=KzqSDvzOFNA)

Happy coding!
+ email: developer.aya.b@gmail.com
+ telegram: [Aya Bouchiha](https://t.me/AyaBouchiha)
Part 2 : Search a REGEX with .test() Method
Tags: javascript, codenewbie, beginners, webdev
Published: 2021-07-24 22:24:49

Hey dear readers!
Welcome to another part of the *JavaScript Regular Expressions* series.
In the introduction part, you've been familiar with the *basic syntax* of `Regular Expressions`.

In this part, we will know **How to Search a REGEX in a String**

The most commonly used method to *search* is the `.test()` method. Let's get started with that. 👇🏻 

### .test() method to search a regex in a string

The `.test()` method takes the regex, applies it to a string (which is placed inside the parentheses), and returns *true* if your pattern finds something similar to the given regex and *false* otherwise. 

The *basic syntax* for this method is: `regex.test(string)`
A simple example is given below.

```js
let codingIsHiding = "Somewhere coding is hiding in this text.";
let codingRegex = /coding/; 
let result = codingRegex.test(codingIsHiding);
console.log(result); 

//output: true
```
The *output* of this example is *true* as the regex *coding* is present in the given string.

### Search a String with Multiple Possibilities with .test()

Sometimes, we need to search for *different possibilities* in a single string. Instead of creating so many different regex, we can search for multiple patterns using the `alternation` or `OR operator: |`. 

```js
let myString = "Swarnali loves rain and snow.";
let weather = /rain|cloud|sun|snow|heat/ ;
let pet = /cats|dogs|birds|fishes/

let weatherResult = weather.test(myString);
let petResult = pet.test(myString);

console.log(weatherResult); //output: true
console.log(petResult); //output: false
```

In the above code snippet, both the *weather* regex and *pet* regex have multiple possibilities to be true for the string. The string contains two possibilities of the weather regex: *rain* and *snow* but does not contain any of the possibilities written in the pet regex. 
So, the first console.log() will return *true* and the second one will return *false* for the given string.

#####In this part, we learnt about *searching a regex in a string* with *single* and *multiple* possibilities with .test() method. In the next part, we will learn another method to search and extract a match from the string.
A Quick 10-Second Programming Joke For Today
Tags: jokes, dailydeveloperjokes
Published: 2021-07-24 22:14:57

---
title: "A Quick 10-Second Programming Joke For Today"
description: "Check out today's daily developer joke! (a project by Fred Adams at xtrp.io)"
series: "Daily Developer Jokes"
published: true
tags: #jokes, #dailydeveloperjokes
---

Hi there! Here's today's Daily Developer Joke. We hope you enjoy it; it's a good one.

![Joke Image](https://private.xtrp.io/projects/DailyDeveloperJokes/public_image_server/images/5e125969479bf.png)

---

For more jokes, and to submit your own joke to get featured, check out the [Daily Developer Jokes Website](https://dailydeveloperjokes.github.io/). We're also open sourced, so feel free to view [our GitHub Profile](https://github.com/dailydeveloperjokes).

### Leave this post a ❤️ if you liked today's joke, and stay tuned for tomorrow's joke too!

_This joke comes from [Dad-Jokes GitHub Repo by Wes Bos](https://github.com/wesbos/dad-jokes) (thank you!), whose owner has given me permission to use this joke with credit._

<!--
Joke text:
___Q:___ What did XHR say to AJAX when it thought it was being a Mean Girl?

___A:___ Stop trying to make fetch happen!
 -->
Regular Expression Part 1 : Introduction
Tags: javascript, webdev, beginners, codenewbie
Published: 2021-07-24 22:09:56

Hello readers! 
In this blog , I am going to write about `JavaSript Regular Expressions`, also commonly known as `REGEX`. This is the first part of this series.

Let's get introduced with *Regular Expressions* 📖

*REGEX* is an object that describes a certain *pattern of characters* which is used to perform *pattern-matching* , *find*, *search and replace* functions on text or strings. It is also very important when we want to validate *emails*, *usernames* or *passwords*.

###Basic Syntax

The *basic syntax* of a regex is : `/pattern/`

A very simple example of searching a regex in a *string* is, you simply have to write your desired pattern inside the / /. 
```js
let testStr = "Search the word regex in this string";
let testRegEx = /regex/;
```
In this introduction part, I want to leave it just to the basic syntax. In the next part, we will learn *how to search a regex within a string*.
Today's Daily Humor For Devs - Daily Developer Jokes
Tags: jokes, dailydeveloperjokes
Published: 2021-07-24 22:05:28

---
title: "Today's Daily Humor For Devs - Daily Developer Jokes"
description: "Check out today's daily developer joke! (a project by Fred Adams at xtrp.io)"
series: "Daily Developer Jokes"
published: true
tags: #jokes, #dailydeveloperjokes
---

Hi there! Here's today's Daily Developer Joke. We hope you enjoy it; it's a good one.

![Joke Image](https://private.xtrp.io/projects/DailyDeveloperJokes/public_image_server/images/5e1259869e0aa.png)

---

For more jokes, and to submit your own joke to get featured, check out the [Daily Developer Jokes Website](https://dailydeveloperjokes.github.io/). We're also open sourced, so feel free to view [our GitHub Profile](https://github.com/dailydeveloperjokes).

### Leave this post a ❤️ if you liked today's joke, and stay tuned for tomorrow's joke too!

_This joke comes from [Dad-Jokes GitHub Repo by Wes Bos](https://github.com/wesbos/dad-jokes) (thank you!), whose owner has given me permission to use this joke with credit._

<!--
Joke text:
___Q:___ What kind of computer can hold a musical note?

___A:___ A Dell.
 -->
Today's Fun Joke For Developers - Daily Developer Jokes
Tags: jokes, dailydeveloperjokes
Published: 2021-07-24 22:03:28

---
title: "Today's Fun Joke For Developers - Daily Developer Jokes"
description: "Check out today's daily developer joke! (a project by Fred Adams at xtrp.io)"
series: "Daily Developer Jokes"
published: true
tags: #jokes, #dailydeveloperjokes
---

Hi there! Here's today's Daily Developer Joke. We hope you enjoy it; it's a good one.

![Joke Image](https://private.xtrp.io/projects/DailyDeveloperJokes/public_image_server/images/5e1259d336eb5.png)

---

For more jokes, and to submit your own joke to get featured, check out the [Daily Developer Jokes Website](https://dailydeveloperjokes.github.io/). We're also open sourced, so feel free to view [our GitHub Profile](https://github.com/dailydeveloperjokes).

### Leave this post a ❤️ if you liked today's joke, and stay tuned for tomorrow's joke too!

_This joke comes from [Dad-Jokes GitHub Repo by Wes Bos](https://github.com/wesbos/dad-jokes) (thank you!), whose owner has given me permission to use this joke with credit._

<!--
Joke text:
___Q___: What good can come of 2989 witches casting a hex?

___A___: None, it is always 0xBAD
 -->
How to clear port 8080 in windows
Tags: webdev, beginners
Published: 2021-07-24 21:56:28


Step 1:

Open up cmd.exe (note: you may need to run it as an administrator, but this isn't always necessary), then run the below command:

```
netstat -ano | findstr <Port Number>
```

(Replace <Port Number> with the port number you want, but keep the colon)



The area circled in red shows the PID (process identifier). Locate the PID of the process that's using the port you want.

Step 2:

Next, run the following command:

```
taskkill /F /PID <Process Id>
```



---
## Example



###### STEP - 1
```
netstat -ano | findstr 8080
```
```
TCP  0.0.0.0:18080    0.0.0.0:0     LISTENING    19788
TCP  [::]:18080       [::]:0        LISTENING    19788
```





###### STEP - 2
```
taskkill /F /PID 19788
```

```
SUCCESS: The process with PID 19788 has been terminated.
```
[Source](https://www.codegrepper.com/code-examples/shell/how+to+clear+port+8080)
Python Basics, Python 101
Published: 2021-07-24 21:18:01

## Introduction
Python is a general-purpose interpreted, interactive, object-oriented, and high-level programming language. It was created by Guido van Rossum during 1985- 1990. Like Perl, Python source code is also available under the GNU General Public License (GPL)

## Why to Learn Python?
Python is a high-level, interpreted, interactive and object-oriented scripting language. Python is designed to be highly readable. It uses English keywords frequently where as other languages use punctuation, and it has fewer syntactical constructions than other languages.
Python is a MUST for students and working professionals to become a great Software Engineer specially when they are working in Web Development Domain. I will list down some of the key advantages of learning Python:
•	Python is Interpreted − Python is processed at runtime by the interpreter. You do not need to compile your program before executing it. This is similar to PERL and PHP.
•	Python is Interactive − You can actually sit at a Python prompt and interact with the interpreter directly to write your programs.
•	Python is Object-Oriented − Python supports Object-Oriented style or technique of programming that encapsulates code within objects.
•	Python is a Beginner's Language − Python is a great language for the beginner-level programmers and supports the development of a wide range of applications from simple text processing to WWW browsers to games

## Python is popular because of the following reasons
Easy-to-learn
Easy-to-read
Easy-to-maintain
A broad standard library
Python supports GUI Programming
Python provides interfaces to all major commercial databases
Python can run on a wide variety of hardware platforms

## Applications of Python
•	Artificial Intelligence
•	Desktop Application
•	Automation
•	Web Development
•	Data Analysis and Visualization

## Installation
Download python from here.

## IDEs
Popular IDEs include
•	PyCharm
•	Kite
•	Spyder
•	IDLE
•	Sublime Text 3
•	Visual Studio Code
•	Atom

## Hello World using Python
console.log('markdown')
print ("Hello, Python!")