teleren/devto huggingface dataset:
python dictionary methods explanation and visualization
Tags: python, tutorial, programming, beginners
Published: 2022-02-19 23:30:29

##python dictionary methods 


####get()	
- Returns the value of the specified key
```
fruits = {'grape': '🍇', 'Watermelon': '🍉', 'banana': '🍌', 'mango': '🥭', 'apple': '🍎'}

x = fruits.get("mango")

# output
🥭
```

####clear() 
- Removes all the elements from the dictionary
```
fruits = {'grape': '🍇', 'Watermelon': '🍉', 'banana': '🍌', 'mango': '🥭', 'apple': '🍎'}
fruits.clear()

# output
{}
```

####copy() 
- Returns a copy of the dictionary
```
fruits = {'grape': '🍇', 'Watermelon': '🍉', 'banana': '🍌', 'mango': '🥭', 'apple': '🍎'}

x = fruits.copy()

# output
{'grape': '🍇', 'Watermelon': '🍉', 'banana': '🍌', 'mango': '🥭', 'apple': '🍎'}

```

####keys() 
- Returns a list containing the dictionary's keys
```
fruits = {'grape': '🍇', 'Watermelon': '🍉', 'banana': '🍌', 'mango': '🥭', 'apple': '🍎'}

x = fruits.keys()

# output
dict_keys(['grape', 'Watermelon', 'banana', 'mango', 'apple'])
```

####update() 
- Updates the dictionary with the specified key-value pairs
```
fruits = {'grape': '🍇', 'Watermelon': '🍉', 'banana': '🍌', 'mango': '🥭', 'apple': '🍎'}
fruits.update({"strawberry":"🍓"})

# output
{'grape': '🍇', 'Watermelon': '🍉', 'banana': '🍌', 'mango': '🥭', 'apple': '🍎', 'strawberry': '🍓' }
```

####values() 
- Returns a list of all the values in the dictionary
```
fruits = {'grape': '🍇', 'Watermelon': '🍉', 'banana': '🍌', 'mango': '🥭', 'apple': '🍎'}
x = fruits.values()

# output
dict_values(['🍇', '🍉', '🍌', '🥭', '🍎'])
```

####pop()	
- Removes the element with the specified key
```
fruits = {'grape': '🍇', 'Watermelon': '🍉', 'banana': '🍌', 'mango': '🥭', 'apple': '🍎'}
fruits.pop('Watermelon')

# output
{'grape': '🍇', 'banana': '🍌', 'mango': '🥭', 'apple': '🍎'}
```

####items() 
- Returns a list containing a tuple for each key value pair
```
fruits = {'grape': '🍇', 'Watermelon': '🍉', 'banana': '🍌', 'mango': '🥭', 'apple': '🍎'}
x = fruits.items()

# output
dict_items([('grape', '🍇'), ('Watermelon', '🍉'), ('banana', '🍌'), ('mango', '🥭'), ('apple', '🍎' )])
```

####fromkeys() 
- Returns a dictionary with the specified keys and value
```
x = ['grape1', 'grape2', 'grape3']
y = '🍇'

fruits = dict.fromkeys(x, y)

# output
{'grape1': '🍇', 'grape2': '🍇', 'grape3': '🍇'}
```


####popitem()	
- Removes the last inserted key-value pair
```
fruits = {'grape': '🍇', 'Watermelon': '🍉', 'banana': '🍌', 'mango': '🥭', 'apple': '🍎'}
fruits.popitem()

# output
{'grape': '🍇', 'Watermelon': '🍉', 'banana': '🍌', 'mango': '🥭'}
```


#### setdefault() 
- Returns the value of the specified key. 
- If the key does not exist: insert the key, with the specified value.
```
fruits = {'grape': '🍇', 'Watermelon': '🍉', 'banana': '🍌', 'mango': '🥭', 'apple': '🍎'}

x = fruits.setdefault("grape", None)

# output
{'grape': '🍇', 'Watermelon': '🍉', 'banana': '🍌', 'mango': '🥭', 'apple': '🍎'}
```

All the best to you.


### Connect with Me 😊
- [LinkedIn](https://www.linkedin.com/in/mahmoud-el-kariouny-822719149/)
- [Twitter](https://twitter.com/Mahmoud42275)
AWS Cognito JWT Verification
Tags: aws, cognito, jwt, security
Published: 2022-02-19 23:24:27

AWS Cognito usually responds with 3 JWTs (`IDToken`, `AccessToken`, `RefreshToken`) for each successful login request. There is a fair chance that your application would use these tokens to 
- secure API requests.
- manage permissions/roles based authorization to the resources.

& other custom authorization requirements.
Usually, `IDToken` & `AccessToken` are verified for such purposes, but not `RefreshToken`. It is there just to refresh the session.

Both `IDToken` & `AccessToken` have some common as well as unique claims so its 100% your own choice to decide where to verify which token according to your use-case.

More on using Tokens [here](https://docs.aws.amazon.com/cognito/latest/developerguide/amazon-cognito-user-pools-using-tokens-with-identity-providers.html)

Find **Cognito JWT Verification Algorithm** here 👉 [github-gist](https://gist.github.com/afraz-khan/65ebd02326480ac96e4ef9c066e0dbea)

You can use same algorithm with minor additions/deletions to verify both `IDToken` & `AccessToken`. This algorithm is written in TypeScript and follows the steps as described in officical Cognito guide [here](https://docs.aws.amazon.com/cognito/latest/developerguide/amazon-cognito-user-pools-using-tokens-verifying-a-jwt.html) to verify the JWTs.

cheers :)
Why Flutter?
Published: 2022-02-19 23:23:59

Flutter is Google's new, efficient UI tool for quickly and easily assembling well-designed apps. Flutter is based on the Dart programming language, which is then converted to native code for Android, iOS, and Web. 

This means that you can create an app that provides as good user experiences as native apps, but with a shorter development time and at a lower cost.

Flutter's Hot Reload function further shortens and streamlines app development, as you can quickly see updates in the app when you create it. Flutter is also extremely flexible in terms of design and functions, which gives you endless possibilities.
How to Explain Cryptocurrency in 2 Minutes
Tags: web3, blockchain
Published: 2022-02-19 23:18:29

> I was confused at first when I set out to understand cryptocurrencies.

It seemed like everyone had their own way of explaining it, and sometimes they would add fluff or buzzwords that just seemed to muddle things.

So here I am, offering a no-nonsense article that takes only 2 minutes to hopefully explains:
- What is cryptocurrency?🤔
- How do they work? ❓
- And why *is* everyone so excited about them?

So here's a summary of the contents from [this article]
(https://decrypt.co/resources/what-are-cryptocurrencies-super-quick-guide)

## What are Cryptocurrencies?

🌐Cryptocurrencies are digital-only tokens.
The key ingredient is *cryptography* which is used to control
- 🪙token creation
- ⚖️trading
- 🔒security

🚫🏦Most importantly it doesn't need or use a central bank or government to manage it.


## The forerunner, Bitcoin
👤First outlined in a whitepaper in 2008 by the anonymous "Satoshi Nakamoto", it was called a "peer-to-peer electronic cash system".

The Bitcoin blockchain then launched in 2009

### What is blockchain?

Blockchain is an alternative to traditional databases.
It is a global ledger that records every transaction made, and stores a copy across every node(computer) in the network.

💪 It provides the backbone that powers cryptocurrencies.

## What are the traits of a Cryptocurrency?

Every cryptocurrency is:
- 🌐digital (completely online)
- 📚decentralized (stored on a public global ledger)
- 👥peer-to-peer (crypto is exchanged directly between parties)

## How are new coins created?

❓Most cryptos create new coins through the process of "mining".

⛏️Mining: groups or individuals use expensive computers to solve cryptographic problems that will allow them to add new transactions to the blockchain.

💰Miners are rewarded with newly created coins.

## Just a replacement for Fiat Money?

❓Is crypto just used to replace $ and £? 
**No!**
These digital assets can be used for different things:
- 💎Ethereum(2015) is designed to power apps that live on the blockchain (Dapps)
- 📂Filecoin(2020) allows people to rent storage space, sorta like Dropbox!


## What's the appeal of crypto?

Why is everyone saying crypto is the next big thing?
Well some factors that make it appealing
- 👤Semi-anonymous
- 🚫No-government
- 🌐Borderless
- 🔒More secure
- ⏩Cheaper, faster transactions 

## Looking towards the future

**🪦You will notice many cryptocurrencies rise and fall**

But cryptocurrencies as a whole, the technology and the industry around them are here to stay.
100 dias de codigo: 74, implementando redux en mi proyecto
Tags: spanish, 100daysofcode, webdev, redux
Published: 2022-02-19 22:37:41

¡Hey hey hey!

Sinceramente Redux es mucho mas facil de lo que pensé aunque me imagino que tendra su complejidad conforme una aplicación crezca. 


![Certificado Redux David Alonso Ruiz](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/utoe6c39hws2gno8f1vj.jpg)

Hoy logre terminar el curso de Redux y mis conclusiones que redux es una herramienta versátil que te permite separar el estado de tu código y asi obtener uno mas limpio y organizado en diferentes partes para mejorar la legibilidad y el control en la aplicación.

Desconozco si habrá formas diferentes de manejar el estado de una forma externa a los componentes. 

### Hoy
- He comenzado a incluir redux en mi proyecto finance creando el estado.
- Practique Touch Typing.
- Termine el curso de redux.

Terminar el curso me ha llenado de motivación suficiente para comenzar a incluirlo de inmediato en mi proyecto. Siento que en algunos días podre lograr integrarlo por completo y asi comenzar a incluirlo en todos los proyectos que vaya creando en adelante.

Espero que tengan mucho éxito en sus proyectos y mucho animo con todo!

Hasta la próxima!

Foto cover de [Marc Mintel](https://unsplash.com/@mmintel?utm_source=unsplash&utm_medium=referral&utm_content=creditCopyText) en [Unsplash](https://unsplash.com/s/photos/dev?utm_source=unsplash&utm_medium=referral&utm_content=creditCopyText)
Get more eyes on your GitHub work without hassle
Tags: python, automation, github, opensource
Published: 2022-02-19 22:29:35

## TL;DR: 

{% github correia-jpv/github-follow-bot no-readme %}

## Intro
So you want to have more people following your open source work, or maybe bring attention to some interesting and cool projects you have highlighted on your profile.
Perhaps, you want to show off more authority, or you just want to see that followers count grow bigger for the heck of it.

Well, you can achieve this by many ways. When your projects are interesting, well-made, and with good documentation, you'll get organic followers. Also, if you engage in others' projects with welcome contributions, discussions, and relevant issues.



![GitHub Follow Bot logo](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/f2b0epurnvexe3tfqkmm.png)

## Automation to the rescue

However, you might want to try to get more followers in a more automated way. Follow back is a decent strategy and this Python [GitHub Follow Bot](https://github.com/Correia-jpv/github-follow-bot) has options for you to choose the follow sources and how the bot will operate. You can selectively unfollow too.

For example, follow 30 followers of the most popular users from Germany:
![GitHub Follow Bot](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/1subkogtyh2pxu8mgjhj.gif)

Other follow sources are:
 - Followers of a target user
 - Usernames from a file


Here's another example for unfollowing everyone who doesn't follow you back with a custom random delay between unfollows from 5 to 15 seconds:
![GitHub Unfollow Bot](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/yh1va0gsh88vx7ckewug.gif)


Download, instructions and more details on the project's repository:
{% github correia-jpv/github-follow-bot no-readme %}
A remarkable Friday
Tags: awesomitylab, codeofafrica, teamwork
Published: 2022-02-19 22:06:48

After spending a week at Awesomity Lab and CodeOfAfrica, my perspective on boot camps transformed.

## 


![Hand holding egg](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/5gnxahylzi1w0bj28gxo.jpg)
Eggs are a low-cost, high-nutrient source of protein. But none of us expected that moving a single egg on a ring held together by 5 threads would teach us two of the most fundamental skills in software engineering: collaboration and creativity. The fact that we had to move the egg and position it on top of an open bottle without speaking taught us that a team's efficacy, communication, collaboration, and combined efforts result in a better end.

**As Henry Ford phrased it;**
> 
If everyone is moving forward together, then success takes care of itself.


![agile methodology](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/olo8n1mmq0iu0maw1955.jpg)
The Agile method of software development removed a significant amount of pressure from all stakeholders involved in the software development process.

![agile vs waterfall](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/786dp50y1wqirrplf96y.png)
Previously, software developers had to meet with their clients only during the requirements definition phase and upon handing over the project to the client. A software system could be in development for more than two years without reaching the outside world, causing clients to abandon the product, or the product could be released late, resulting in a small market if other similar goods were delivered earlier.
The agile technique stresses software developers working in teams with a client who has a complete understanding of what is being done and why. From the definition of user stories to the release of the product to the public, the client collaborates closely with software developers.
Miro is a tool that I learned about for the first time, and I was blown away by how well it facilitates teamwork in design and strategic planning. 

![challenge image](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/m51hy0n34pbhbv5sfb9f.jpg)
We worked in pairs on coding challenges, commonly known as katas, which were designed to help us improve our critical thinking skills through the use of data structures and algorithms.

The 16 personalities website https://www.16personalities.com/ was used to learn about our roles and personality types, as well as to team up with people with similar personalities to practice public speaking and produce on-point presentations.

![table tennis racket](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/4s7k7x2wwbv2mvh0kdtr.jpg)
Finally, I can't leave without mentioning Friday, an excellent day for interns to set aside what they've been working on all week, put aside the coding issues and join together with all of the employees from both organizations to relax, drink, and enjoy activities like table tennis and football.
3 ways to improve developer skills
Tags: podcast, swift
Published: 2022-02-20 03:59:46

---
title: 3 ways to improve developer skills
published: true
date: 2022-02-19 21:59:00 UTC
tags: Podcasts, Swift
canonical_url: https://peterwitham.com/podcasts/cs-s04-e03/?utm_source=rss&utm_medium=rss&utm_campaign=cs-s04-e03
---

I have 3 tips that I believe will help you become a better developer regardless of skill level. Listen/Read on!

{% spotify spotify:episode:5z8Pz5E5uo5g25WYsvpP5u %}
How to Write Portfolio for DevOps Engineer?
Tags: beginners, devops
Published: 2022-02-19 21:31:51

---
title: How to Write Portfolio for DevOps Engineer?
published: true
description: how to write portfolio for devops engineer
tags: beginners, devops
//cover_image: https://direct_url_to_image.jpg
---

Not like Frontend / Backend engineer, how DevOps, cloud infrastructure, etc create a portfolio?
Some Concepts of backend 
Tags: node, backend
Published: 2022-02-19 21:04:27

 Q.  CRUD Operations. 
CRUD Meaning: CRUD is an acronym that comes from the world of computer programming and refers to the four functions that are considered necessary to implement a persistent storage application: create, read, update and delete.

Q. JWT .
WT, or JSON Web Token, is an open standard used to share security information between two parties — a client and a server. Each JWT contains encoded JSON objects, including a set of claims. JWTs are signed using a cryptographic algorithm to ensure that the claims cannot be altered after the token is issued.

Q .What is a mongoose used for?

Mongoose is an Object Data Modeling (ODM) library for MongoDB and Node. js. It manages relationships between data, provides schema validation, and is used to translate between objects in code and the representation of those objects in MongoDB.

Q. Is MySQL is a relational database?
MySQL databases are relational.
The logical model, with objects such as databases, tables, views, rows, and columns, offers a flexible programming environment. ... SQL is the most common standardized language used to access databases.
 
Q.What is aggregation and example?
Aggregation is the process of combining things. That is, putting those things together so that we can refer to them collectively. As an example, think about the phone numbers on your cell phone. You can refer to them individually - your mother's number, your best friend's number, etc.
 
Q. Express
Express. js is a free and open-source web application framework for Node. js. It is used for designing and building web applications quickly and easily.
JavaScript code puzzle: convert a Boolean to Number
Tags: javascript, puzzle, beginners
Published: 2022-02-19 20:53:21

Write a function `fn` that receives a Boolean and returns it's representation as a Number. So `true` becomes `1` and `false` becomes `0`. 

Contstraints:

- no `Number` constructor or any of it's prototype allowed
- no `Math` functions allowed
- no `toNumber` implementations allowed either
- Strings of numbers, such as `'1'` and `'0'` do not count
- Assume the function always receives a valid boolean (so no `null` or `undefined` or other types need to be considered).

Tests:

```
 console.assert(fn(true) === 1)
 console.assert(fn(false) === 0)
```

Note: 

It's marked as `#beginners`, because it's solution easier than you might think.

Bonus:

It's possible to solve it with 9 characters overall.
TeleIn
Tags: azuretrialhack, node, android
Published: 2022-02-19 20:41:06

[Instructions]: # (To submit to the Microsoft Azure Trial Hackathon on DEV, please fill out all sections.)


### Overview of My Submission
I have build an authentication system where user can login in the application(android) with the help of Telegram (Bot service). In this system , any user has not to go through any hassel. Any user just need to follow the steps to login the **TeleIn** app

1. Go to **TeleIn** app's login page
2. Click Login and it will redirect to **Telegram** app
3. Now in **Telegram** , just click start
4. The **_TeleIn Telegram Bot_** will provide a link
5. Click the link and you will be redirect to the **TeleIn**
6. By default it'll take your Telegram name, you can change it now and Submit.

That's it. Its too simple. No OTP no email comfirmation no extra auth flow! Just simple!

[Cosmos DB](https://docs.microsoft.com/en-us/azure/cosmos-db/introduction) is the place where I store the data of user safely using the Node server.


### Submission Category: 
**Wacky Wildcards**


### Link to Code on GitHub

#### Server
{% github https://github.com/JoyMajumdar2001/telein-server %}

#### Android
{% github https://github.com/JoyMajumdar2001/TeleIn-Android %}


### Additional Resources / Info

#### Tech Used

1. [Cosmos DB](https://docs.microsoft.com/en-us/azure/cosmos-db/introduction)
2. [Telegram Bot](https://core.telegram.org/bots)
3. [Render](https://render.com)

#### Demo
<video width="320" height="800" controls>
  <source src="https://bafybeigudm4ljexyo6qrjwpumkw6t4kblgyau7hjv7raqfycvmvjmpogce.ipfs.dweb.link/Record_2022-02-20-01-32-15.mp4" type="video/mp4">
Your browser does not support the video tag.
</video>
My first week in taskForce 5.0 at Code of Africa and Awesomity lab
Tags: mobile, futter
Published: 2022-02-19 20:19:11

**Introduction**

Am part of a taskforce that's uplifting, developing developers for better skills to be implemented for greater good. You may ask your self what a taskforce is? Well, isn't simply defined as a group of people who are temporary assigned to work together to achieve a very specific and clearly defined objective. 

Awesomity lab is, the best opportunity l encountered for polishing more of my few skills l had as a developer into a skilled developer. More of my experience and gain will be shared in the below phases.

**what was your experience in the first week of the taskforce like for you?**



My first week experience at the taskforce team to me was more of being nervous and accepting the fact that l found to be the only girl in nine boys! However a time went by, l got to feel comfortable among them, gained a lot of skills like soft skills, project management etc. I also had the best working environment that's supportive, fun, partook on different hangouts, let's say l really appreciate the work ethic in my first week a to the taskforce.


**As the only girl who attended this taskforce intern, what motivated to be part of this intern opportunity?**


My motivation is simply a result of what am passionate about which is mobile application and l grew to want grow more of my skills regarding that area. Therefore when l saw the awesome opportunity to gain more skills, l didn't hesitate to take my chances and here l am.

As I include, joining the taskforce has been the best decision l made, l met great people, gain a lot of insights and skills in field. Can't wait for more of these experiences and other weeks as l gain more skills and knowledge
⚙️ ❮ ZBrowse ❯
Tags: zsh, tooling, testing, shell
Published: 2022-02-19 20:17:55

[https://z.digitalclouds.dev](https://z.digitalclouds.dev) | [GitHub](https://github.com/z-shell) | [Twitter](https://twitter.com/zshell_zi)

</div>

---

When doing shell work, it is often the case that `echo $variable` is invoked multiple times, to check result of a loop, etc. With ZBrowse, you just need to press <kbd>Ctrl-B</kbd>, which invokes the `ZBrowse` – `Zshell` variable browser:


![ZBrowse](https://github.com/z-shell/zbrowse/raw/main/docs/images/zbrowse.png)


(you can resize the video like any web page)


[![asciicast](https://asciinema.org/a/122018.png)](https://asciinema.org/a/122018)


## Install zbrowse


First install the [ZUI](https://github.com/z-shell/zui) plugin (it's an UI library).


**The plugin is "standalone"**, which means that only sourcing it is needed. So to install, unpack `zbrowse` somewhere and add


```zsh
source {where-zbrowse-is}/zbrowse.plugin.zsh
```


to `zshrc`.



If using a plugin manager, then `ZI` is recommended, but you can use any other too, and also install with `Oh My Zsh` (by copying directory to `~/.oh-my-zsh/custom/plugins`).



### [ZI](https://github.com/z-shell/zi)



Add `zi load z-shell/zbrowse` to your `.zshrc` file. ZI will handle cloning the plugin for you automatically the next time you start zsh. To update run `zi update z-shell/zbrowse` (`update-all` can also be used).



### Antigen



Add `antigen bundle z-shell/zbrowse` to your `.zshrc` file. Antigen will handle cloning the plugin for you automatically the next time you start zsh.



### Oh-My-Zsh



1. `cd ~/.oh-my-zsh/custom/plugins`
2. `git clone git@github.com:z-shell/zbrowse.git`
3. Add `zbrowse` to your plugin list



### Zgen



Add `zgen load z-shell/zbrowse` to your .zshrc file in the same place you're doing your other `zgen load` calls.
Is it possible to install/setup SDL2 and C++ on a chromebook?
Tags: sdl, codenewbie, programming, cpp
Published: 2022-02-19 20:05:44

I have a Chromebook with Visual Studio Code that I've been using for python, and I want to start learning C++ by making simple games using SDL2.
But I can't find any tutorials on how to setup and install it. Please can anybody help?