teleren/devto huggingface dataset:
My Dev Experience Season 1 Ep 2
Tags: developer, software, python
Published: 2022-07-25 06:28:47

Continuing with my series....

2015 some guy reached out, he needed a website for some construction company
We agreed on the terms and I started working on the website 
took me 3 days to build a demo as he had requested a demo site 
and after that he requested me to work on the main website 
gave me access to their hosting and cpanel then I started building the site, it took me 1 week to build the whole site 

After the site was done.... It was time for the guy to pay up and it took almost 1 year for the guy to pay...in of which the payment never came through from the guy

Out of rage I logged in to the cpanel and deleted the whole project 

This was my first experience with a client
AWS IAM
Tags: aws, devops, beginners
Published: 2022-07-25 06:28:00

## Covers features and elements of IAM

1. What is IAM?
2. Groups, Users and Roles
3. IAM Policies
4. MFA
5. IAM Federation
6. IAM Features

Get the details last from the understanding

## What is IAM?

To manage, control and govern authentication, authorization and access control mechanisms of identities to your resources within AWS Account.

## IAM Components
1. Users
2. Groups
3. Roles
4. Policies
5. Access control and mechanisms.

IAM is globally avaliable AWS services, ie. IAM is not regionally available services and we can create regional specific policies and accesses to an AWS resources.

_Without IAM there is no way of maintaining security or control access to the resources. IAM provides components to manage access, but it is only as strong as we configure it. The responsibility of implementing secure, robust and tight security within AWS is ours._

You can find the IAM services under security, Identity and compliance. 


![AWS Service path inside aws console](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/35ndadhihbauif7rpthd.jpg)

>  All services -> Security, Identity and compliance -> IAM (Manage access to AWS resources)

IAM Responsibilities:
1. How secure your access control procedures must be?
2. How much should admin restrict users access?
3. How complex password policies must be?
4. Resource should use MFA or not?

Admin can architect and implement upto the policies and security guidances from the company or self. 

Restrictions and access are purely based on our own security standards and policies within our information and security management systems. 

**Elements of AWS**

1. [Users, Groups & Roles](https://dev.to/sathish3sank/users-groups-roles-31ge)
2. [Policies & MFA](https://dev.to/sathish3sank/policies-and-mfa-3ie0)


Other resources:
[aws.plainenglish.io](https://aws.plainenglish.io/aws-identity-and-access-management-iam-f084e5915cc5)
Pure functions in javaScript
Tags: javascript, functional, beginners, webdev
Published: 2022-07-25 06:10:21

### Functions

>People think that computer science is the art of geniuses but the actual reality is the opposite, just many people doing things that build on each other, like a wall of mini stones.***Donald Knuth***

Functions are bread and butter of JavaScript programming. The concept of warping a piece of code in a block has many values. In JavaScript functions are ***first class citizens***. First class citizen basically mean that functions are able to do everything that other can.

- ***Functions can be assigned to a variable***

- ***Function can be passed as an argument***

- ***Function can be returned from a function***

A program is a collection of blocks of code that are called functions. Functions in programming are same as function in Math let take an example
In Math we write functions like this ***f(x)=x+2***
This simply means that a function takes x as an input and return x+2. lets now create a program if the above function .
```
function addTwo(x){
return x+2
}
```
The ***addTwo*** is the programming implementation of  ***f(x)=x+2*** this function . The ***addTwo*** function is a ***Pure function***

### Pure Function
For a function to be pure  it have to meet the following two conditions,

- *** Given the same input the same output should be returned. ***

- ***No side effects.***

Lets now try to defend our statement about the addTwo function being pure. we will have to check if the addTwo function meets the above mentioned conditions if it does then we will be successfull in defending our statment.

*** Given the same input the same output should be returned ***
lets pass 2 as an input.
```
console.log(addTwo(2))
 It will return 4
```

Now it does't matter how many times we pass the value of 2 the function addTwo will always return 4. So it is clear that our addTwo function satesfies the first condition of Pure function.

Lets now try to verify the second condition.

*** No Side Effects **
what is side effect?
When a function modifies or relies on anything outside or its parameters then the function has side  effects.

The above function of ours is not using anything outside of its parameter which means that it setisfies the second condition of pure function.

It is concluded that our *** addTwo function is a pure function***

A principle of identifying a pure function.
<aside>
If calling a function without using its return value makes sense then it is not a pure function.
</aside>

### Why you should use pure functions?

- Easy to refactor and move around.
- Independent of outside world.
- Simplest reusable block of code.
- Immune to bugs outside of its scope.
- Makes programs more adaptable to future changes


### Conclusion
A computer program is a collection of small blocks of code that are called function. 
Pure functions are function that when given same input will return the same output and pure function don't have side effects. Pure functions are independent of out side and can easily be refactored.
How to Insert a Chart in the React Spreadsheet Component
Tags: react, webdev, reactnative
Published: 2022-07-25 06:10:03

Learn how easy it is to insert a chart in the Syncfusion [React Spreadsheet component](https://www.syncfusion.com/react-ui-components/react-spreadsheet). 

In this video, a chart has been inserted in a specific cell position by using the chart property. You can also insert a chart by using the insert-Chart method. To enable or disable this feature, use the allow-Chart property in the Spreadsheet component. You can change the height and width of the chart by resizing it and moving it to another position by dragging and dropping it. 

Product overview: https://www.syncfusion.com/react-ui-components/react-spreadsheet

Download an example from GitHub: https://github.com/SyncfusionExamples/how-to-insert-a-chart-in-the-react-spreadsheet-component

Refer to the following chart documentation: https://ej2.syncfusion.com/react/documentation/spreadsheet/illustrations/#chart

{% youtube WmZwTiTbqbI %}
js-sdsl - A javascript standard data structure library
Tags: javascript, typescript
Published: 2022-07-25 05:46:14

A javascript standard data structure library with reference to C++ STL, the English name is javascript standard data structure library

github link: https://github.com/ZLY201/js-sdsl

npm link: https://npmjs.com/js-sdsl

Contains various data structures such as Set, Map and hash table implemented using RB-tree, with extremely complete unit tests and performance tests and complete api documentation

It supports CommonJS and ES modules, and supports the introduction of browser script tags. It is written in typescript and has rigorous type inference, making development more efficient.

If you have any ideas or find any loopholes, please submit a merge request or contact me, we will put your information on the contributor list and display it on the homepage
Major Projects For Ece In Embedded Systems
Tags: beginners, programming, embedded, projects
Published: 2022-07-25 05:41:50

Engineering student projects for b.tech and m.tech final year students. takeoff edu group offers a wide range of projects best for [major projects for ece in embedded systems](https://takeoffprojects.com/major-projects-for-ece-in-embedded-systems) looking for magnificent final projects at low cost. 
 
We have successfully delivered major projects for ece in embedded systems to our engineering students. Our programs are specially designed by experts for best results of major projects for ece in embedded systems for engineering students. max of the b.tech, m.tech, PHD and diploma scholars.
 
Takeoff edu group provides the most creative conceptions and ideas that can make very effective final year projects for scholars, experimenters, and engineers. so browse through our list of [major projects for ece in embedded systems](https://www.youtube.com/watch?v=IGpAc1Gc4SA) and choose the smart final year projects for your requirements moment.
 
Top5 Major Projects for ECE in Embedded Systems:
Drowsiness Detection System using Eye Aspect Ratio Technique
Energy-efficient Face Recognition Authentication System Using Human Detection IoT Modules
Smart Agriculture Using Internet of Things with Raspberry Pi
Real-Time Smart Home Surveillance System of Based on Raspberry Pi
Real Time Application of Vehicle Anti Theft Detection and Protection with Shock Using Facial Recognition and IoT Notification

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/3s2iuc8lcmjvp6v4ky6l.png)

An embedded system is some combination of computer hardware and software, either fixed in capability or programmable, that's specifically designed for a particular function. Artificial machines, motorcars, medical outfit, cameras, house appliances, aeroplanes , putting up machines and toys( as well as the more obvious cellular phone and PDA) are among the myriad possible hosts of an embedded system. Embedded systems that are programmable are handed with programming interfaces

The technological inventions in the Embedded Systems lead to the extended operation of it over a wide range of operations. Embedded systems are found in operations that range from simple consumer- electronic widgets to largely-complex artificial outfit. This system uses electronic factors in confluence with computer network systems to have control of colorful outfit. The Embedded system consists of a single- chip microcontroller or microprocessor that acts as the central control to the interfaced supplemental devices.
34. Leetcode Solution in Java
Tags: dailychallenge, java
Published: 2022-07-25 05:13:01

```
class Solution {
    public int[] searchRange(int[] nums, int target) {
        if(nums == null) return new int[]{-1, -1};
        int len = nums.length;
        int index = binarySearch(0, len - 1, nums, target);
        if(-1 == index) return new int[]{-1, -1};
        else{
            int high = index;
            while(++high < len && nums[high] == target){};
            int low = index;
            while(--low >= 0 && nums[low] == target){}
            return new int[]{low + 1, high - 1};
        }
    }
    private static int binarySearch(int low, int high, int[] nums, int target){
        if(low > high)
            return -1;
        int mid = low + (high - low) / 2;
        int midVal = nums[mid];
        if(midVal == target) return mid;
        if(midVal > target)
            return binarySearch(low, mid - 1, nums, target);
        else
            return binarySearch(mid + 1, high, nums, target);
    }
}
```

#Leetcode
#challenge
Here is the link for the problem:
https://leetcode.com/problems/find-first-and-last-position-of-element-in-sorted-array/
Build a Messenger Clone with MERN Stack (MongoDB, Express, React, Node JS) + Socket.io (Day 12)
Tags: react, javascript, webdev, tutorial
Published: 2022-07-25 04:45:11

In this Facebook Messenger Clone Tutorial series, we will learn to build an Awesome Full Stack Facebook Messenger Project with realtime messaging functionality with socket.io . We have one on one chat as well as group chatting functionality in this app.

In this video,we will learn how to change the page Title in react

{% youtube yvtlpPQFJPI %}
Features of JavaScript - That You Should Know
Tags: javascript, webdev, beginners, programming
Published: 2022-07-25 04:39:57

JavaScript is a front-end language, the most utilized language nowadays by developers to design web pages or web applications. Developers use this language to make a transcendent framework to make their work more attractive. ECMAScript version(ES6+) of JavaScript is the latest version now to use and there are lots of advanced functions.

Features of JavaScript
### 1. Style Console Log

you know that? you can style the console log by using JavaScript. To customize the console log you need to add CSS on it to get the console log. If you want to print the source code you need to add %c before the code and then add console.log() after it. But it requires CSS to variable to execute it. 

If you want to customize the variable in comparison to others you need to use %c and console.log() before it. And add CSS properties as you want in it. 

Let's see the example:

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/n6fiiywe1p1eb6wwhbro.png)

### 2. Use Shorthand Operators
ES6 has a shorthand to define operators in a short way. And this is an operator that no one can talk about simply because they don't know about it. This operator makes your work easy and fast. And it looks very clean and neet to read and understand.
Let's see the example:

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/6wx50kxvq8prx64fd6rj.png)

### 3. Elective Chaining
Chaining ?. is used to check properties before ?.  if it's null or undefined then it returns undefined otherwise its returns the value.

Developers have a lot of work and projects to complete before a time. Source code has large objects, nested loops, containers, for that to check the property.

Let's see the example:

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/iqxgzckh5f1gxkhme7te.png)

### 4. Use Generator Function
This is a function that similar to common functions the only difference between them is Generator function stops the execution on a particular line when you want and continue when you want. To create the generate function you need to use * after keyword of function.

Let's see the example:

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/yjs7vu5tdkfx4g1cey7y.png)

### 5. Use in Keyword
in keyword is used to check the properties are available in an object or not. After using this keyword you can get the true or false value its depend on the value that available in an object or not. 

Let's see the example:

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/4w7foxtlbwrns62s4tmh.png)
version control with git
Tags: versio, control, with, git
Published: 2022-07-25 04:14:53

VERSION CONTROL WITH GITHUB 
Version control is a system that helps to monitor changes to collections of information such as files/documents, computer programs etc. It monitors changes/modifications made to a file so that in the future specific versions can be recalled.

What is git?
Git is a free open source distributed version control system that helps to track changes made in any set of files and makes collaboration between programmer more easier and more effective.

Git terminologies 
Here are some of the most common terminologies or key words when using git for version control 
1. Git init: it is used to initialize git 
2. Git add [file name]: adds files to the staging area. ‘git add .’ command is used to upload all files to git at once 
3. Git commit: used to commit git to local repository 
4. Git push: used to move files to remote repository 
5. Git status: used to check what files are present in the staging area and what files need to be committed 
6. Git log: list all the files committed to a repository
HOW TO MANAGE YOUR DAY?
Tags: management, programming, webdev, productivity
Published: 2022-07-25 04:09:00

Not only a web developer or a programmer should know how to manage their daily routine but in my opinion everyone should follow a routine to live a well balanced life. 

Here is mine formula of living a well balanced life.

- 
Before touching mobile & doing 1st thing in the morning, make a chit/slip for works you have to do today. It will help you to achieve efficiency and increase our productivity. (30mins or 1hrs works time table.)

- Efficiency = Alertness = Slip of work list you have to finish.

- 
1 day = 24hrs / 3 i.e. 8x8x8

- First "8" = Give it completely to your profession.

- 
Second "8" = Take rest or Sleep, don't compromise with it.

- Third "8" = Very imp. to like a happy life & enjoy it.  

- Divide it in 9 compartments as given below:

FFF = FAMILY, FRIENDS & FAITH
HHH = HEALTH, HYGINE & HOBBY
SSS = SOUL, SERVICE & SMILE

- "WELL LIVED BALANCED LIFE"


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/073hatem7xle5bqyu3du.jpg)
Ext JS Combobox with condition
Published: 2022-07-25 03:15:00

Hello everyone, I'm newbie in Ext JS. I have a problem while handling combobox event. 
My application use EXT JS to display GIS data as a table. Users can edit the data by editing directly on the table. Example, I have some GIS data on the map like this: 

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/xkk1px072ujhgux055sr.png)

These data can be displayed as a table like this:

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/bmd302pqg464ejvp9cfn.png)

In this table, 'type' column is used as combobox. It include some values: [Schemas Node, Schemas Cable Coiling Frame, Schemas Street Cabinet, Schemas Duct Access Chamber, Schemas Ducts, Schemas Fiber Cable]. This problem here is that when displaying data as table, 'type' column will be filtered to return the appropriate values. 
- For Polygon object, it will return [Schemas Fiber Cable]. 
- For LineString object, it will return [Schemas Fiber Cable,  Schemas Ducts]. 
- For Point object it will return [Schemas Node, Schemas Cable Coiling Frame, Schemas Street Cabinet, Schemas Duct Access Chamber]. 


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/ap7z5iqyllacmebr9k28.png)

What should I do. Thank's for reading. 
Sorry my English is not good.
Make VS Code Faster for Python Auto-Completion
Tags: python, vscode
Published: 2022-07-25 03:01:00

I've always struggled with how slow `Pylance` `IntelliSense` becomes when a project gets large. It turns out that with a minor tweak, my system is super speedy again!

Try adding a [`pyrightconfig.json` file](https://github.com/microsoft/pyright/blob/main/docs/configuration.md) to the root of your project. By excluding folders that you don't need to be indexing (`node_modules`, `cdk.out`, etc.) you may see a significant boost.

Here is a simple example:

```json
{
    "include": [
        "."
    ],
    "exclude": [
        "**/node_modules",
        "**/cdk.out",
        "**/.pytest_cache",
        "**/build",
        "**/dist",
        "**/.vscode",
        "**/__pycache__",
    ],
    "reportMissingImports": true,
}
```

Share any other tips you have in the comments!
Using The Python Docstring To Document Functions
Tags: python, tutorial, beginners
Published: 2022-07-25 02:54:07

I was working through a tutorial on [Real Python](realpython.com) and learned an interesting fact that filled a gap I had noted previously.

A few years ago, I wrote a small Python app to process data from a source to a SQL Server destination. I had been picking up small portions of Python since 2017; while I had enough knowledge to create a working solution, there were many things I know I would have liked to refactor or do more efficiently. One such item was the desire to provide a description for the functions I was abstracting out for the app.

In the Real Python tutorial, the teacher was discussing [docstrings](https://peps.python.org/pep-0257/), a string literal. When it occurs as the first statement in a function, it performs as a special attribute and displays an explanation of the function. The best practice is that it should not be a repeat of the function signature, since that will be displayed already, but a brief explanation of purpose of the function.

Here is an example of a function without a docstring - only the function signature, if provided, is displayed:

```Python
def function1():
    return "Hi there"
```

![function with no docstring](https://kristenkinnearohlmann.dev/static/bed6127bf9c8874e27a4ee8459056948/23313/function-no-docstring.jpg)

Here is an example of function with a docstring - the contextual help displays the text from the docstring as well as the function signature, if any:

```Python
def function2():
    """Returns a greeting in Portuguese with no variable"""
    return "Ola, prazer em conhecer"
```

![function with docstring](https://kristenkinnearohlmann.dev/static/3760f58d277aefdb4c5b1cac6e31ad23/8e1fc/function-with-docstring.jpg)

This clears up mysteries in your code, whether all your functions reside in the same file or not. You can quickly recall why you abstracted away the code and how you intended to use it. This functionality can and should be used for methods that are members of a class so developers using your code understand the purpose of the method. All of the same best practices will apply.

When I have an opportunity to refactor my data processing Python app, I will take advantage of docstrings to help me and other contributing developers quickly understand what each function is doing.
What programming language is best for cyber security?
Tags: javascript, tutorial, java, python
Published: 2022-07-25 02:23:39


There are many programming languages that can be used for cyber security including but not limited to Java, C++, Python, Ruby and PHP. It is important to choose the right language for a given task because different languages have different features that make them better suited for certain types of tasks. For example, Java has been shown to be effective at building modular applications and handling large data sets while C++ is well known for its strength in creating robust software systems.

## 5 **[Top Tips to Become a Better Software Engineer](https://professional-writer0.blogspot.com/2022/07/5-tips-for-working-remotely-as-junior.html)**

Cyber security programming languages come in all shapes and sizes, but they share a few key features. They are all designed to make it easier to write code, and to make the code more secure. They all have features that make it easier to automate tasks, and to check the code for mistakes. They also have features that make it easier to work with data.

## [How to Become a Backend Developer: Important Skills to Learn](https://professional-writer0.blogspot.com/2022/07/build-your-developer-roadmap-5-steps-to.html)

One of the most important features of a cyber security programming language is the ease of use. Programmers need to be able to write code quickly and easily, without having to learn a lot of complicated terminology. They need to be able to write code that is easy to read, and that makes it easy to understand what is going on.

Cyber security programming languages are typically used for two purposes: to write code that is used to secure computer systems, and to write code that is used to monitor and control computer systems. There are a number of different cyber security programming languages, but the two most commonly used are Java and Python. Java is used more often than Python, but both languages are used for different purposes.

There is no one “best” cyber security programming language. Different languages are better suited for different purposes. Java is used more often than Python, but both languages are used for different purposes.