computer_science_and_programming | Неотсортированное

Telegram-канал computer_science_and_programming - Computer Science and Programming

158177

Channel specialized for advanced topics of: * Artificial intelligence, * Machine Learning, * Deep Learning, * Computer Vision, * Data Science * Python For Ads: @otchebuch & @cobbl, https://telega.io/c/computer_science_and_programming

Подписаться на канал

Computer Science and Programming

18 Most common used Java List methods

1. add(E element) - Adds the specified element to the end of the list.
2. addAll(Collection<? extends E> c) - Adds all elements of the specified collection to the end of the list.
3. remove(Object o) - Removes the first occurrence of the specified element from the list.
4. remove(int index) - Removes the element at the specified position in the list.
5. get(int index) - Returns the element at the specified position in the list.
6. set(int index, E element) - Replaces the element at the specified position in the list with the specified element.
7. indexOf(Object o) - Returns the index of the first occurrence of the specified element in the list.
8. contains(Object o) - Returns true if the list contains the specified element.
9. size() - Returns the number of elements in the list.
10. isEmpty() - Returns true if the list contains no elements.
11. clear() - Removes all elements from the list.
12. toArray() - Returns an array containing all the elements in the list.
13. subList(int fromIndex, int toIndex) - Returns a view of the portion of the list between the specified fromIndex, inclusive, and toIndex, exclusive.
14. addAll(int index, Collection<? extends E> c) - Inserts all elements of the specified collection into the list, starting at the specified position.
15. iterator() - Returns an iterator over the elements in the list.
16. sort(Comparator<? super E> c) - Sorts the elements of the list according to the specified comparator.
17. replaceAll(UnaryOperator<E> operator) - Replaces each element of the list with the result of applying the given operator.
18. forEach(Consumer<? super E> action) - Performs the given action for each element of the list until all elements have been processed or the action throws an exception.

Читать полностью…

Computer Science and Programming

Do you enjoy reading this channel?

Perhaps you have thought about placing ads on it?

To do this, follow three simple steps:

1) Sign up: https://telega.io/c/computer_science_and_programming
2) Top up the balance in a convenient way
3) Create an advertising post

If the topic of your post fits our channel, we will publish it with pleasure.

Читать полностью…

Computer Science and Programming

If you design complex systems, you'll love sequence diagrams

Complex system architectures can quickly become tangled and hard to follow. Enter sequence diagrams! They keep your design neat and easily understandable.

For example, check out the diagram below. It depicts a client/server interaction, clearly differentiating between a cache hit and a cache miss. This is a prime example of how visual aids simplify complex interactions.

Sequence diagrams are a must when you aim to:

- 🚀 Map out end-to-end system workflows.
- 🔍 Clarify interactions between components.
- 📚 Produce clear and concise documentation.
- 🔧 Identify design flaws.

I have two favorites for creating sequence diagrams. WebSequenceDiagrams and Mermaid (links in comment). You can make sequence diagrams easily with just text.

Do you have a go-to tool for crafting good-looking sequence diagrams? Drop your suggestions below! 👇

Читать полностью…

Computer Science and Programming

Leveraging SAM for Single-Source Domain Generalization in Medical Image Segmentation

📄 https://arxiv.org/pdf/2401.02076.pdf

💻 https://github.com/SARIHUST/SAMMed

@computer_science_and_programming

Читать полностью…

Computer Science and Programming

Ever wondered how your computer securely communicates with a remote server? 🤔

Let's dive into the magic behind SSH and unravel its secrets. 🔍💻

1. What is SSH? 🤷‍♂️
SSH, or Secure Shell, is a cryptographic network protocol that enables secure communication between two devices over an unsecured network. It's like a secure tunnel for your data! 🚇🔒

2. Key Players: Public and Private Keys 🗝
SSH uses a pair of cryptographic keys – a public key (shared with the world) and a private key (kept super-secret). 🤫 When you connect, these keys perform a digital handshake to ensure a secure connection. 🤝🔑

3. The Handshake Dance: Authentication 💃
The handshake involves your computer proving its identity using the private key, and the server verifying it using the corresponding public key. Think of it as a secret password exchange, but way cooler! 😎🕵️

4. Encryption Enchantment: Securing the Chat 🛡
Once the handshake is complete, SSH wraps your data in layers of encryption, ensuring that even if someone intercepts it, they'll find nothing but gibberish. 🤐📡

5. Port Perfection: Default Port 22 🚪
SSH communicates through port 22 by default. It's like the entrance to your secure data party! 🎉🚪 But beware, changing ports adds an extra layer of security. 🕵️‍♀️🔐

SSH is the superhero of secure communication, ensuring your data remains confidential, and the connection is trustworthy. 🦸‍♂️💼 Next time you SSH, remember the cryptographic dance happening in the background, making it all possible! 🕺🌐

Читать полностью…

Computer Science and Programming

18 most used Linux commands YOU MUST KNOW

- ls
- mv
- ssh
- cd
- cat
- sudo
- pwd
- grep
- top
-mkdir
- find
- wget
- rm
- chmod
- tar
- cp
- chwon
- gzip

Читать полностью…

Computer Science and Programming

Explore Human Parsing Modality for Action Recognition

📄 https://arxiv.org/pdf/2401.02138.pdf

💻 https://github.com/liujf69/EPP-Net-Action

Читать полностью…

Computer Science and Programming

NoSQL vs SQL

NoSQL databases provide flexible data models ideal for diverse data structures and scalability.

1. Key-Value: Simple, uses key-value pairs (e.g., Redis).
2. Document: Stores data in JSON/BSON documents (e.g., MongoDB).
3. Graph: Manages complex relationships with nodes and edges (e.g., Neo4j).
4. Column Store: Optimized for analytics, organizes data by columns (e.g., Cassandra).

SQL databases, like RDBMS and OLAP, provide structured, relational storage for traditional and analytical needs

1. RDBMS: Traditional relational databases with tables (e.g., PostgreSQL & MySQL).
2. OLAP: Designed for complex analysis and multidimensional data (e.g., SQL Server Analysis Services).

Читать полностью…

Computer Science and Programming

Instagram System Design Overview

- Clients (iOS, Android, Web).
- Microservices for varied functionalities.
- Databases: MySQL, Cassandra, Redis.
- Object storage (Amazon S3) & CDN for media.
- Caching with Memcached/Redis
- Scaling, load balancing, auto-scaling.
- Asynchronous processing with queues
- Secure authentication (OAuth), RBAC.
- Monitoring (Prometheus, Grafana) & analytics.
- Push notifications for real-time updates.

Читать полностью…

Computer Science and Programming

Here’s description of 9 types of API testing:

➡️ 1. Unit Testing: Involves testing individual components or functions of an API in isolation to ensure they function correctly and produce the expected output.

➡️ 2. Functional Testing: Focuses on testing the overall functionality of the API, verifying that it performs as intended and produces accurate results.

➡️ 3. Integration Testing: Tests interactions between different components or services within an API to ensure they work together seamlessly and communicate effectively.

➡️ 4. Load Testing: Evaluates the API's performance under heavy load by simulating a large number of concurrent requests to identify potential bottlenecks and optimize resource usage.

➡️ 5. Security Testing: Aims to identify vulnerabilities in the API by testing for potential security risks, such as unauthorized access, data leakage, or injection attacks.

➡️ 6. Stress Testing: Pushes the API beyond its limits by applying extreme conditions, such as high traffic or limited resources, to determine how well it can handle such scenarios.

➡️ 7. Negative Testing: Involves deliberately sending invalid or incorrect inputs to the API to verify that it responds appropriately with error messages or other expected behaviors.

➡️ 8. Boundary Testing: Focuses on testing the limits of the API's inputs, such as minimum and maximum values, to ensure it handles these boundaries correctly.

➡️ 9. Usability Testing: Evaluates the user-friendliness of the API by assessing how easily developers can understand its documentation, endpoints, and responses, ultimately enhancing the developer experience.

Читать полностью…

Computer Science and Programming

5 Principles of Object Oriented Design (SOLID)

Читать полностью…

Computer Science and Programming

🌟 Why Clean Architecture?

✅ Maintainability: Changes in one layer won't lead to a domino effect of changes throughout the codebase. 🔄🚫

✅ Testability: Each layer is testable in isolation, making it easier to ensure your code works as expected. ✔️🧪

✅ Scalability: You can swap out components without disrupting the entire system. It grows with your project! 📈🔄

✅ Adaptability: Technology evolves, but your core business logic remains intact. Upgrades are smoother and less painful. ⚙️🔧

📚 Layers of Clean Architecture:

- Entity Layer: The core business logic lives here. It represents the heart of your application. ❤️🧠
- Use Case Layer: This layer holds application-specific use cases and business rules. It orchestrates interactions between entities and ensures they stay clean and focused. 🤝📋

- Interface Adapters: These adapters bridge the gap between the use cases and the external world, like user interfaces and databases. They keep things flexible and adaptable. 🌐🔌

- Frameworks & Drivers: The outermost layer deals with frameworks, tools, and external systems. It's where you connect to databases, APIs, and UI frameworks. 🖥🔗

Читать полностью…

Computer Science and Programming

Top Programming Languages of All Times

Читать полностью…

Computer Science and Programming

7 Popular Network Protocols

1- HTTPS: Secure version of HTTP, used for secure communication over a computer network.

2 - Web Socket: Provides full-duplex communication channels over a single TCP connection.

3 - TCP: Provides reliable, ordered, and error-checked delivery of a stream of bytes.

4 - HTTP: Foundation of any data exchange on the Web, a protocol used for transmitting hypertext.

5 - FTP: Used for the transfer of computer files between a client and server on a computer network.

6 - UDP: Allows computer applications to send messages, in this case referred to as datagrams, to other hosts on an Internet Protocol (IP) network.

7 - SMTP: Internet standard for email transmission across Internet Protocol (IP) networks.

Читать полностью…

Computer Science and Programming

Sharing the tool that will make working with text easier!

CMD+ helps to make your day-to-day tasks easier and faster while providing you with customization options so that you can tailor the interface to fit your needs. With just a few simple commands, you can easily take care of various tasks such as text writing, translation, Excel promts, and rephrasing, eliminating the hassle of manually doing those activities. By automating these time-consuming processes, CMD+ saves you time and energy, allowing you to focus on more important tasks.

Download:
https://cmdplus.page.link/H3Ed

Читать полностью…

Computer Science and Programming

Ever wondered how Docker 🐳 works?

1. Docker Build 🏗
2. Docker Push ☁️
3. Docker Run 🏃
4. Docker Pull 🚚
5. Docker Images 🖼

Читать полностью…

Computer Science and Programming

🔵 Welcome to Sky Source! 🟡

Since 2018, we've been the go-to advertising community, helping businesses expand their audience and acquire clients on Telegram.

💬 Our Channels:

• @Manchester_City
• @Real_Madrid
• @Cristiano
• @Juventus
...
@Programming
• @Elon_Musk

... and 75 more!

📈 Our Benefits:

• Over 80 channels with a combined audience of >2.2 million followers.
• GEO targeting from Europe, USA, Latin America, and beyond.
• Guaranteed 394,000+ views with high conversion rates across all channels.
• Payment methods include: Crypto (BTC, USD-T), Card/PayPal (via exchangers), MTN Mobile, Opay.

➡️ Find the full price list and detailed conditions here:
/channel/sky_source/97

👨‍💻 Contact us to book your ad:
@cobbl or @otchebuch

Читать полностью…

Computer Science and Programming

Improving API Performance with Database Connection Pooling

The diagram below shows 5 common API optimization techniques. Today, I’ll focus on number 5, connection pooling. It is not as trivial to implement as it sounds for some languages.

When fulfilling API requests, we often need to query the database. Opening a new connection for every API call adds overhead. Connection pooling helps avoid this penalty by reusing connections.

How Connection Pooling Works

1. For each API server, establish a pool of database connections at startup.
2. Workers share these connections, requesting one when needed and returning it after.

Challenges for Some Languages

However, setting up connection pooling can be more complex for languages like PHP, Python and Node.js. These languages handle scale by having multiple processes, each serving a subset of requests.

- In these languages, database connections get tied to each process.
- Connections can't be efficiently shared across processes. Each process needs its own pool, wasting resources.

In contrast, languages like Java and Go use threads within a single process to handle requests. Connections are bound at the application level, allowing easy sharing of a centralized pool.

Connection Pooling Solution

Tools like PgBouncer work around these challenges by proxying connections at the application level.

PgBouncer creates a centralized pool that all processes can access. No matter which process makes the request, PgBouncer efficiently handles the pooling.

At high scale, all languages can benefit from running PgBouncer on a dedicated server. Now the connection pool is shared over the network for all API servers. This conserves finite database connections.

Connection pooling improves efficiency, but its implementation complexity varies across languages.

Читать полностью…

Computer Science and Programming

Monolithic VS Microservices Architecture. Which one are you using? 🤔

In the realm of software architecture, the choice between Monolithic and Microservices can shape the destiny of your application. Let's break down the key differences in a nutshell! 🧩

1. Monolithic Architecture 🏰

- One Big Castle: Monoliths are like a majestic castle, where all components (database, server, user interface) are tightly knit into a single structure.

- Unified & Simple: Easy to develop and deploy due to its unified structure. Changes are made in one place, making coordination a breeze.

- Scaling Challenges: Scaling can be a challenge. When one aspect needs upgrading, the entire application must be scaled, even if only a small part requires more resources.

2. Microservices Architecture 🌐

- City of Specialized Buildings: Microservices resemble a bustling city, with each service as a specialized building handling a distinct function.

- Scalability & Flexibility: Offers scalability on a per-service basis. If one part of the application needs more resources, you can scale just that service.

- Increased Complexity: As the number of services grows, managing the communication between them can become complex. Decentralization brings its own set of challenges.

Читать полностью…

Computer Science and Programming

🌐 Public vs Internal Load Balancers: Unveiling the Power of Balance! 🔄

Load balancing is the unsung hero of seamless digital experiences, and choosing between public and internal load balancers can be a game-changer. Let's dive into the key differences in a nutshell! 🚀

🌍 Public Load Balancers:
- Audience: Everyone, Everywhere!
- Designed to distribute incoming traffic across public-facing servers.
- Ideal for applications accessible over the internet, such as websites or APIs.
- Acts as the gateway, directing external requests to the right internal resources.

🏢 Internal Load Balancers:
- Keep it in the Family:
- Tailored for distributing traffic within a private network or data center.
- Perfect for applications serving internal users or specific services behind the scenes.
- Enhances security by keeping sensitive systems shielded from the public eye.

🤔 How to Choose?
- Public:
- Opt for when your services need to be accessible from the internet.
- Ideal for handling high volumes of external traffic.
- Best suited for public-facing applications like websites or APIs.

Читать полностью…

Computer Science and Programming

Public Static Void Main(String[] args) Explained.

public: An access modifier keyword that indicates the class (MainClass) is accessible from outside the package.

class: A keyword used to declare a class in Java.
MainClass: The name of the class. It follows the naming conventions for classes in Java.

{ and }: Curly braces define a block of code. In this case, they enclose the body of the class.

public: An access modifier keyword indicating that the main method can be called from outside the class.

static: A keyword indicating that the main method belongs to the class itself rather than to an instance of the class.

void: A keyword indicating that the main method does not return any value.

main: The name of the method. It is the entry point for the Java program.

(String[] args): The method parameter list. String[] args is an array of strings that can be used to pass command-line arguments to the program.

System.out.println("Hello, World!");: A statement that prints the string "Hello, World!" to the console. System.out is an object representing the console output, and println is a method to print a line.

Читать полностью…

Computer Science and Programming

6 Software ARCHITECTURAL PATTERNS

- Event Driven
- Layered
- Monolithic
- Microservice
- MVC
- Master Slave

Читать полностью…

Computer Science and Programming

12 Most Common git Commands YOU MUST KNOW

- init
- clone
- status
- add
- commit
- push
- pull
- branch
- checkout / switch
- merge
- diff
- log

Читать полностью…

Computer Science and Programming

GridFormer: Point-Grid Transformer for Surface Reconstruction

Paper:
https://arxiv.org/pdf/2401.02292.pdf

GitHub:
https://github.com/list17/GridFormer

🔗@computer_science_and_programming

Читать полностью…

Computer Science and Programming

Top 4 Forms of Authentication Mechanisms

1. SSH Keys - Cryptographic keys are used to access remote systems and servers securely

2. OAuth Tokens - Tokens that provide limited access to user data on third-party applications

3. SSL Certificates - Digital certificates ensure secure and encrypted communication between servers and clients

4. Credentials - User authentication information is used to verify and grant access to various systems and services

Читать полностью…

Computer Science and Programming

❗️Java vs. Python❗️

➡️ Python and Java are both popular and powerful programming languages, each with its own unique strengths. Python is known for its simplicity and readability, making it an excellent choice for beginners and rapid development. Its concise syntax allows developers to express concepts with fewer lines of code, promoting faster iteration and prototyping. Python's extensive library ecosystem empowers developers to access a wide range of pre-built tools for various tasks.

➡️ On the other hand, Java is recognized for its platform independence and robustness. It's a statically-typed language, which means errors can be caught at compile time, enhancing code reliability. Java's "write once, run anywhere" philosophy enables applications to run on different platforms without modification, thanks to the Java Virtual Machine (JVM). This also makes Java well-suited for building large-scale, performance-critical applications.

➡️ In summary, Python emphasizes simplicity, readability, and rapid development, while Java prioritizes platform independence, robustness, and performance. The choice between the two largely depends on the project's requirements and the developer's preferences.

Читать полностью…

Computer Science and Programming

CI/CD example for API written in Java/Spring Boot.

👉 CI/CD stands for Continuous Integration/Continuous Deployment. It is a software development process that involves automating the building, testing, and deployment of code changes.

🏭 The CI/CD pipeline can be thought of as a factory assembly line, where each step is automated to ensure the code is high quality and ready for deployment.

🛠 The pipeline starts with Continuous Integration, where code changes are automatically built, tested, and merged into a shared repository. This step helps catch errors early and ensures the code is stable and functioning correctly.

📦 Once the code has passed the integration tests, it moves on to Continuous Deployment. This step involves automatically packaging and deploying the code changes to a staging or production environment.

👀 Automated testing is performed at each stage of the pipeline to ensure that the code meets the required standards and that the new changes do not break any existing functionality.

🚀 The ultimate goal of a CI/CD pipeline is to speed up the software development process, reduce errors, and quickly deliver new features and improvements to users.

Читать полностью…

Computer Science and Programming

12 Microservices Best Practices You Should Know

1 - Single Responsibility
2 - Containers
3 - Orchestration
4 - Resilience and Fault Tolerance
5 - Scalability
6 - CI/CD
7 - Observability
8 - Security
9 - API Gateway
10 - Stateless
11 - DB Per Service
12 - Event Driven Architecture

Читать полностью…

Computer Science and Programming

Make sure you're using a premium VPN!!

Download and use OrcaVPN and get:

🗺 VPN split tunnelling
⚡️ Speed test
⭐ IP Checker
👑 Ad blocker
✅ High speed and low ping
✔️ Access restricted Apps 🎮📱📱

1 month
free with CODE: SECRET. Then only $4.99 $0.99 👀😎

⏬️⏬️⏬️⏬️⏬️⏬️⏬️
https://7etap.app.link/OrcaVPN

Читать полностью…

Computer Science and Programming

How do companies ship code to production?

Step 1: The process starts with a product owner creating user stories based on requirements.

Step 2: The dev team picks up the user stories from the backlog and puts them into a sprint for a two-week dev cycle.

Step 3: The developers commit source code into the code repository Git.

Step 4: A build is triggered in Jenkins. The source code must pass unit tests, code coverage threshold, and gates in SonarQube.

Step 5: Once the build is successful, the build is stored in artifactory. Then the build is deployed into the dev environment.

Step 6: There might be multiple dev teams working on different features. The features need to be tested independently, so they are deployed to QA1 and QA2.

Step 7: The QA team picks up the new QA environments and performs QA testing, regression testing, and performance testing.

Steps 8: Once the QA builds pass the QA team’s verification, they are deployed to the UAT environment.

Step 9: If the UAT testing is successful, the builds become release candidates and will be deployed to the production environment on schedule.

Step 10: SRE (Site Reliability Engineering) team is responsible for prod monitoring.

Читать полностью…
Подписаться на канал