The document discusses arrays and motivates their use. It explains that arrays allow storing a large number of values in a program and accessing them through indices. Arrays solve the problem of having to declare many individual variables to store multiple values. The document then introduces the concept of arrays, how to declare and initialize array variables, and how to access elements within an array using indices. It provides examples of declaring, initializing, and accessing one-dimensional and two-dimensional arrays.
To define methods, invoke methods, and pass arguments to a method (§5.2-5.5).
To develop reusable code that is modular, easy-to-read, easy-to-debug, and easy-to-maintain. (§5.6).
To use method overloading and understand ambiguous overloading (§5.7).
To design and implement overloaded methods (§5.8).
To determine the scope of variables (§5.9).
To know how to use the methods in the Math class (§§5.10-5.11).
To learn the concept of method abstraction (§5.12).
To design and implement methods using stepwise refinement (§5.12).
This document provides an overview of Java collections basics, including arrays, lists, strings, sets, and maps. It defines each type of collection and provides examples of how to use them. Arrays allow storing fixed-length sequences of elements and can be accessed by index. Lists are like resizable arrays that allow adding, removing and inserting elements using the ArrayList class. Strings represent character sequences and provide various methods for manipulation and comparison. Sets store unique elements using HashSet or TreeSet. Maps store key-value pairs using HashMap or TreeMap.
In this chapter we are going to get familiar with some of the basic presentations of data in programming: lists and linear data structures. Very often in order to solve a given problem we need to work with a sequence of elements. For example, to read completely this book we have to read sequentially each page, i.e. to traverse sequentially each of the elements of the set of the pages in the book. Depending on the task, we have to apply different operations on this set of data. In this chapter we will introduce the concept of abstract data types (ADT) and will explain how a certain ADT can have multiple different implementations. After that we shall explore how and when to use lists and their implementations (linked list, doubly-linked list and array-list). We are going to see how for a given task one structure may be more convenient than another. We are going to consider the structures "stack" and "queue", as well as their applications. We are going to get familiar with some implementations of these structures.
In this chapter we will learn about arrays as a way to work with sequences of elements of the same type. We will explain what arrays are, how we declare, create, instantiate and use them. We will examine one-dimensional and multidimensional arrays. We will learn different ways to iterate through the array, read from the standard input and write to the standard output. We will give many example exercises, which can be solved using arrays and we will show how useful they really are.
This document discusses collections and queries in Java, including associative arrays (maps), lambda expressions, and the stream API. It provides examples of using maps like HashMap, LinkedHashMap and TreeMap to store key-value pairs. Lambda expressions are introduced as anonymous functions. The stream API is shown processing collections through methods like filter, map, sorted and collect. Examples demonstrate common tasks like finding minimum/maximum values, summing elements, and sorting lists.
In this chapter we will get familiar with primitive types and variables in Java – what they are and how to work with them. First we will consider the data types – integer types, real types with floating-point, Boolean, character, string and object type. We will continue with the variables, with their characteristics, how to declare them, how they are assigned a value and what is variable initialization.
19. Data Structures and Algorithm ComplexityIntro C# Book
In this chapter we will compare the data structures we have learned so far by the performance (execution speed) of the basic operations (addition, search, deletion, etc.). We will give specific tips in what situations what data structures to use. We will explain how to choose between data structures like hash-tables, arrays, dynamic arrays and sets implemented by hash-tables or balanced trees. Almost all of these structures are implemented as part of NET Framework, so to be able to write efficient and reliable code we have to learn to apply the most appropriate structures for each situation.
This document summarizes Chapter 6 of Liang's Introduction to Java Programming, Ninth Edition. It introduces arrays as a data structure that represents a collection of the same type of data. It describes how to declare array variables, create arrays, initialize arrays, access array elements using indexes, and use array initializers. It also provides examples of common array operations and how to trace a sample program that uses arrays.
This document discusses loops in Java, including while, do-while, and for loops. It provides examples and explanations of each loop type, how they work, and how to trace their execution. Key points covered include initialization, condition testing, and updating in for loops, avoiding infinite loops, and using nested loops to repeat loops within loops.
The document discusses various concepts related to abstraction in software development including project architecture, code refactoring, enumerations, and the static keyword in Java. It describes how to split code into logical parts using methods and classes to improve readability, reuse code, and avoid repetition. Refactoring techniques like extracting methods and classes are presented to restructure code without changing behavior. Enumerations are covered as a way to represent numeric values from a fixed set as text. The static keyword is explained for use with classes, variables, methods, and blocks to belong to the class rather than object instances.
In this chapter we will review how to work with text files in C#. We will explain what a stream is, what its purpose is, and how to use it. We will explain what a text file is and how can you read and write data to a text file and how to deal with different character encodings. We will demonstrate and explain the good practices for exception handling when working with files. All of this will be demonstrated with many examples in this chapter
In this chapter we are going to get familiar with recursion and its applications. Recursion represents a powerful programming technique in which a method makes a call to itself from within its own method body. By means of recursion we can solve complicated combinatorial problems, in which we can easily exhaust different combinatorial configurations, e.g. generating permutations and variations and simulating nested loops. We are going to demonstrate many examples of correct and incorrect usage of recursion and convince you how useful it can be.
The document contains the solutions to 64 programming problems in Java. It provides the code to write programs that can:
1) Display patterns like right angle triangles and pyramids with numbers.
2) Check if a number is negative, zero or positive.
3) Sort arrays and insert or find elements in arrays.
4) Perform operations like calculating averages and separating even/odd numbers in arrays.
3) Find pair sums and rotate/add matrices.
This document summarizes Chapter 13 of Liang's Introduction to Java Programming textbook. It discusses graphics and drawing in Java, including:
- Java's coordinate system and how each GUI component has its own coordinate space
- Using the Graphics class to draw strings, lines, rectangles, ovals, arcs and polygons
- Overriding the paintComponent method to draw on a component
- Examples of drawing different shapes and using classes like FigurePanel and MessagePanel
Encapsulation provides benefits such as reducing complexity, ensuring structural changes remain local, and allowing for validation and data binding. It works by hiding implementation details and wrapping code and data together. Objects use private fields and public getters/setters for access. Access modifiers like private, protected, and public control visibility. Validation occurs in setters through exceptions. Mutable objects can be modified after creation while immutable objects cannot. The final keyword prevents inheritance, method overriding, or variable reassignment.
The document discusses arrays in object-oriented programming. It introduces arrays as a data structure that represents a collection of the same data types. It then covers declaring and creating arrays, accessing array elements using indexes, initializing arrays, and other array operations like copying, searching, and processing elements. The document is intended as a teaching reference for working with arrays in programming.
In this chapter we will explore strings. We are going to explain how they are implemented in C# and in what way we can process text content. Additionally, we will go through different methods for manipulating a text: we will learn how to compare strings, how to search for substrings, how to extract substrings upon previously settled parameters and last but not least how to split a string by separator chars. We will demonstrate how to correctly build strings with the StringBuilder class. We will provide a short but very useful information for the most commonly used regular expressions. We will discuss some classes for efficient construction of strings. Finally, we will take a look at the methods and classes for achieving more elegant and stricter formatting of the text content.
This document provides an overview and introduction to developing Android apps using a hybrid approach with HTML5, jQuery, Apache Cordova and the Android SDK. It begins with background information about the author and their experience developing Android apps. It then outlines an agenda for two days of training on this topic. The rest of the document addresses frequently asked questions about Android and the hybrid app development process through short explanations and diagrams. Key topics covered include what Android is, its architecture, tools used for hybrid app development like Cordova and Eclipse, and how to structure an Android project.
This document discusses developing mobile web apps using HTML5, jQuery, and PhoneGap/Apache Cordova. It covers the hybrid approach of using HTML/CSS/JavaScript for the front-end and PhoneGap to package it as a native mobile app. Tools mentioned include Apache Cordova, Node.js, Eclipse, and Xcode. It provides an overview of key topics to be covered in subsequent days, such as the mobile web page structure using jQuery Mobile, connecting to online databases using PHP and MySQL, and building apps with PhoneGap Build.
The document discusses reading and writing text files in Java. It shows how to use the PrintWriter class to write data like names and scores to a text file. It then demonstrates using the Scanner class to read the data back from the file by parsing the strings and integers. The example writes two names and scores to a file, and then reads and prints out the same data.
The document discusses the File class in Java, which represents files and directories on disk without providing file processing capabilities. It describes the File class constructors and common methods like exists(), isFile(), isDirectory(), getPath(), and list(). Examples are provided to demonstrate analyzing a file or directory path specified by the user, including checking if it exists, retrieving information about it, and listing the contents if it is a directory. The document also notes some common errors like using \ instead of \\ in file paths in string literals.
http://KOKUIS.my/html5
HTML5 – refers to the modern day of HTML which promotes native handling of video & audio & animation without having to install additional plugins to browser.
.
Bootstrap – A HTML framework supports responsive web design to provide one time webpage development for smartphone, tablet and desktop.
.
Mobirise – a free web design studio that support HTML5 & Bootstrap’s famous ‘block’ design.
The document discusses arrays in Java. It begins by defining an array as a data structure that holds a collection of the same type of data. It then covers topics such as declaring and creating arrays, accessing array elements using indexes, default values, passing arrays to methods, returning arrays from methods, and two-dimensional arrays. Examples are provided throughout to illustrate key concepts related to working with arrays in Java programs.
This document summarizes Chapter 7 of Liang's Introduction to Java Programming textbook. It discusses single-dimensional arrays, including declaring and creating arrays, accessing array elements using indexes, initializing arrays, and common array operations like finding minimum/maximum elements and shifting elements. The objectives cover array fundamentals as well as applying arrays to problems and using methods with array arguments and return values.
At the end of this lecture students should be able to;
Describe the C arrays.
Practice the declaration, initialization and access linear arrays.
Practice the declaration, initialization and access two dimensional arrays.
Apply taught concepts for writing programs.
1) Arrays allow storing and accessing multiple values of the same data type. They are declared with the data type, followed by square brackets and the array name.
2) Array components are accessed using their index number within square brackets after the array name. Index numbers start at 0.
3) The length property returns the number of components in the array, which must be considered to avoid accessing components outside the bounds of the array.
An array is a collection of similar elements that are stored in contiguous memory locations. Arrays in C can have one or more dimensions. One-dimensional arrays are declared with the type of elements, name of the array, and number of elements within brackets (e.g. int marks[30]). Multi-dimensional arrays represent matrices and are declared with the number of rows and columns (e.g. int arr[5][10]). Individual elements within an array are accessed via indices (e.g. arr[2][7]). Pointers in C are related to arrays - the name of an array represents the address of its first element, and pointer arithmetic can be used to access successive elements in an array.
The document discusses arrays in Java. It begins by introducing arrays as data structures that hold a collection of the same type of data elements. It then covers how to declare, create, initialize and access array elements using indexed variables. The document explains using array initializers to declare, create and initialize an array in one statement. It also discusses default element values, finding an array's length, and examples of using arrays in programs including a detailed step-by-step trace of an array example program.
The document discusses one-dimensional arrays in C++. It defines an array as a series of elements of the same type that can be referenced collectively by a common name. These elements are placed in consecutive memory locations and can be individually referenced using a subscript or index. The document covers declaring and initializing one-dimensional arrays, accessing array elements individually and collectively, inputting and displaying array elements, and provides examples of programs that work with arrays.
The document discusses multidimensional arrays and provides examples of declaring and using two-dimensional arrays in Java. It describes how to represent tables of data using two-dimensional arrays, initialize arrays, access elements, and perform common operations like summing elements. The document also introduces the concept of ragged arrays and declares a three-dimensional array could be used to store student exam scores with multiple parts.
The document discusses arrays in Java. It begins by defining what an array is - a structured data type that stores a fixed number of elements of the same type. It then covers how to declare and initialize one-dimensional arrays, manipulate array elements using loops and indexes, and how to pass arrays as parameters to methods. The document also discusses arrays of objects and multidimensional arrays.
This document provides an overview of NumPy arrays, including how to create and manipulate vectors (1D arrays) and matrices (2D arrays). It discusses NumPy data types and shapes, and how to index, slice, and perform common operations on arrays like summation, multiplication, and dot products. It also compares the performance of vectorized NumPy operations versus equivalent Python for loops.
This document discusses arrays and their uses. Arrays allow programs to efficiently organize and access similar data. The document introduces one-dimensional arrays, using an array to track figure skating scores as an example. It explains how to declare and initialize arrays, access elements using indexes, and iterate over arrays using for loops. The document also discusses using arrays to collect input data, such as tallying votes in an election, and representing translation tables.
This document discusses arrays in Java. It covers concepts like array rotation, inserting values into sorted arrays while maintaining sort order, using arrays with String and Graphics methods, initializing and using arrays of objects, avoiding null pointer exceptions, passing command line arguments as arrays, and using the Arrays utility class methods like binarySearch, sort, and toString. Examples are provided to demonstrate array rotation, searching/sorting numbers, and parsing command line arguments.
An array is a container that holds a fixed number of values of the same type. Arrays in Java are created in three steps: 1) declare the array name and type, 2) create the array using new, and 3) initialize the array values. The length of an array is fixed at creation. Arrays can be one-dimensional, containing a list of values, or multi-dimensional, containing other arrays. Elements in arrays are accessed via an index with the first element at index 0.
1. An array is an object that stores a list of values of the same type and is made up of contiguous memory divided into slots indexed from 0 to N-1.
2. One-dimensional arrays use a single subscript to access elements, while two-dimensional and higher dimensional arrays use multiple subscripts to represent rows and columns.
3. Arrays are declared with the syntax Type[] name = new Type[size]; and elements can be accessed using name[index].
1. An array is a collection of variables of the same type that are referred to by a common name. Arrays provide a convenient way of grouping related data of the same type.
2. Arrays organize data in a way that allows for easy manipulation and sorting of elements. Declaring data as an array is more elegant than declaring many individual variables when multiple pieces of related data are involved.
3. C# supports one-dimensional and multi-dimensional arrays. Elements in arrays are accessed using an index. Arrays are zero-indexed and bounds checked to prevent errors. The Length property provides the size of the array.
The document contains solutions to chapter 7 questions from ANCI C programming. It includes explanations and code for problems related to one-dimensional arrays, two-dimensional arrays, multi-dimensional arrays, dynamic arrays, initializing and accessing array elements, and more. Multiple choice and fill-in-the-blank questions are provided with answers. Programming exercises cover topics like finding the slope and y-intercept of a line, maximum/minimum temperature analysis, vote counting, and generating Pascal's triangle.
The document discusses arrays in Java, including how to declare and initialize one-dimensional and two-dimensional arrays, access array elements, pass arrays as parameters, and sort and search arrays. It also covers arrays of objects and examples of using arrays to store student data and daily temperature readings from multiple cities over multiple days.
This document discusses arrays in C#, including declaring and creating arrays, accessing array elements, input and output of arrays, iterating over arrays using for and foreach loops, dynamic arrays using List<T>, and copying arrays. It provides examples of declaring, initializing, accessing, reversing, and printing arrays. It also covers reading arrays from console input, checking for symmetry, and processing arrays using for and foreach loops. Lists are introduced as a resizable alternative to arrays. The document concludes with exercises for practicing various array techniques.
This document provides information on arrays in Java. It begins by defining an array as a collection of similar data types that can store values of a homogeneous type. Arrays must specify their size at declaration and use zero-based indexing. The document then discusses single dimensional arrays, how to declare and initialize them, and how to set and access array elements. It also covers multi-dimensional arrays, providing syntax for declaration and initialization. Examples are given for creating, initializing, accessing, and printing array elements. The document concludes with examples of searching arrays and performing operations on two-dimensional arrays like matrix addition and multiplication.
Dokumen tersebut membahas sejarah perkembangan ilmu pengetahuan dan masyarakat, termasuk definisi ilmu pengetahuan, pengaruh ilmu pengetahuan dalam peradaban dunia, era digital dan perbedaan antara masyarakat bermaklumat dengan masyarakat berpengetahuan.
This document discusses Islam in the era of information and communication technology (ICT). It states that Islam's core belief is that Allah is the creator of all things, and that the purpose of creation is for humans to worship Allah and act as stewards of the earth. While ICT provides benefits, it also poses challenges like the spread of false information and exposure of youth to inappropriate content without oversight. The document argues that Islamic principles of maintaining balance, protecting faith, life, intellect and society, and eliminating harm can help address issues in the ICT era.
Application of Ontology in Semantic Information Retrieval by Prof Shahrul Azm...Khirulnizam Abd Rahman
Application of Ontology in Semantic Information Retrieval
by Prof Shahrul Azman from FSTM, UKM
Presentation for MyREN Seminar 2014
Berjaya Hotel, Kuala Lumpur
27 November 2014
This document provides information about a course on fundamentals of Java programming taught by Khirulnizam Abd Rahman. It includes details about the instructor's background and programming experience, course synopsis and objectives, assessment methods, required textbooks, and an outline of topics to be covered such as control structures, methods, arrays, classes, and file I/O. The topic outline lists lessons on selection structures including if-else statements and switch cases, as well as repetition structures and nested control flows.
This document provides information about a course on Java programming fundamentals taught by Khirulnizam Abd Rahman. It includes details about the lecturer's background and programming experience, the course synopsis and objectives, main textbooks, and topics that will be covered such as control structures, methods, arrays, classes, and file I/O. Sample code is provided to demonstrate if/else and switch statements, including nested if statements. An exercise at the end prompts students to write a program using nested if/else statements to assign grades based on scores.
This course is the continuation of the previous course (Algorithm and Problem Solving). It introduces complex flow control, method, array, class design, file and file I/O.
Kursus ini membincangkan adab pengendalian maklumat, isu-isu yang berkaitan dengan teknologi komputer dan teknologi maklumat. Penggunaan komputer peribadi dengan memberi pendedahan kepada perkakasan dan perisian komputer. Membincangkan mengenai internet, telekomunikasi serta pencarian maklumat melalui web. Membentuk pelajar yang beradab dalam pengendalian dan pengurusan maklumat.
This document provides guidance on writing a review paper in 3 sentences or less. It outlines the simple skeleton of a review paper including the title, affiliation, abstract, introduction, previous works, and conclusion sections. The document recommends reading sample papers and provides page by page guidance for completing each section of the paper within the 5 page limit. It emphasizes gaining experience by writing and encourages participants to draft their paper.
AIRS 2014 is the 10th annual Asia Information Retrieval Societies Conference that will be held in Kuching, Sarawak, Malaysia from December 3-5, 2014. The conference is hosted by the Malaysia Society of Information Retrieval and Knowledge Management and aims to bring together researchers to exchange ideas in the field of information retrieval, covering applications in text, audio, video and multimedia. Authors are invited to submit original papers by May 22, 2014 on topics related to information retrieval models, evaluation, web search, multimedia retrieval, natural language processing and machine learning.
With Android phones being produced by all of the major phone manufacturers and with the addition of new tablet devices, it's no surprise that the Android platform is the fastest growing mobile development platform in the world. In this course, you will learn to develop Android applications using Java and the Eclipse development environment. You will learn basic application development including using the Android mobile camera, working with local database, and playing audio and video files.
At the end of the course, participant should be able to;
• Use Eclipse and the Android ADT plugin to develop and debug Android applications
• Set up text input from the hardware or software keyboard
• Display scrolling lists and grids with custom layouts
• Listen and react to touch events
• Manipulating Audio
• Handling Video
• Developing Multimedia Apps
This document describes a mobile app that was developed to detect Malay proverbs in sentences using pattern matching. It discusses related works on multiword indexing and proverb dictionaries. The app uses a simple pattern matching algorithm to detect proverbs by searching word combinations in a proverb database. Challenges include dealing with affixes and stop words. Future work includes improving detection by adding stemming and stop word removal. The prototype aims to help learners of the Malay language and further study of syntactic rules is suggested.
Ayat-ayat al-Quran dan Doa-doa yang terdapat di dalam helaian ini adalah seperti yang terdapat di dalam applikasi m-mathurat. Kami juga menyertakan suara bacaan al-Ma’thurat di dalam applikasi mobil tersebut. Sila muat-turun dari:
http://bit.ly/mathurat
The document outlines an agenda and topics for an Android development 101 training session over two days. Day one will cover creating an Android project, widgets and interactions, and HTML/WebView. Day two will cover audio, video, signing APKs, and uploading to the Google Play store. The document also provides answers to frequently asked questions about Android topics like what Android is, its architecture, available versions, tools for development, and distributing apps. Demo portions are planned to accompany the topics.
Khirulnizam - students experience in using blog as a learning tool - world co...Khirulnizam Abd Rahman
Abstract
This paper is to report a study on the students’ experience in using blog (weblog) as a learning tool. For the purpose of this study, a blog was prepared for the subject of Web Programming. This blog is a place where the lecturer posts the syllabus, lecture notes, presentations slides, computer lab manual, assignments, discussions, code samples and also announcements. The students are required to visit the blog to download the learning materials and to participate in the discussions. It is a quantitative survey to find out whether the students having a good or bad experience in using the blog. The authors also would like to know the students’ experience in using the blog; in terms of flexibility, content presentation or arrangement, communication, experience through blog, update medium, navigation and overall experience.
Kief Morris rethinks the infrastructure code delivery lifecycle, advocating for a shift towards composable infrastructure systems. We should shift to designing around deployable components rather than code modules, use more useful levels of abstraction, and drive design and deployment from applications rather than bottom-up, monolithic architecture and delivery.
Transcript: Details of description part II: Describing images in practice - T...BookNet Canada
This presentation explores the practical application of image description techniques. Familiar guidelines will be demonstrated in practice, and descriptions will be developed “live”! If you have learned a lot about the theory of image description techniques but want to feel more confident putting them into practice, this is the presentation for you. There will be useful, actionable information for everyone, whether you are working with authors, colleagues, alone, or leveraging AI as a collaborator.
Link to presentation recording and slides: https://bnctechforum.ca/sessions/details-of-description-part-ii-describing-images-in-practice/
Presented by BookNet Canada on June 25, 2024, with support from the Department of Canadian Heritage.
論文紹介:A Systematic Survey of Prompt Engineering on Vision-Language Foundation ...Toru Tamaki
Jindong Gu, Zhen Han, Shuo Chen, Ahmad Beirami, Bailan He, Gengyuan Zhang, Ruotong Liao, Yao Qin, Volker Tresp, Philip Torr "A Systematic Survey of Prompt Engineering on Vision-Language Foundation Models" arXiv2023
https://arxiv.org/abs/2307.12980
7 Most Powerful Solar Storms in the History of Earth.pdfEnterprise Wired
Solar Storms (Geo Magnetic Storms) are the motion of accelerated charged particles in the solar environment with high velocities due to the coronal mass ejection (CME).
Quantum Communications Q&A with Gemini LLM. These are based on Shannon's Noisy channel Theorem and offers how the classical theory applies to the quantum world.
Scaling Connections in PostgreSQL Postgres Bangalore(PGBLR) Meetup-2 - MydbopsMydbops
This presentation, delivered at the Postgres Bangalore (PGBLR) Meetup-2 on June 29th, 2024, dives deep into connection pooling for PostgreSQL databases. Aakash M, a PostgreSQL Tech Lead at Mydbops, explores the challenges of managing numerous connections and explains how connection pooling optimizes performance and resource utilization.
Key Takeaways:
* Understand why connection pooling is essential for high-traffic applications
* Explore various connection poolers available for PostgreSQL, including pgbouncer
* Learn the configuration options and functionalities of pgbouncer
* Discover best practices for monitoring and troubleshooting connection pooling setups
* Gain insights into real-world use cases and considerations for production environments
This presentation is ideal for:
* Database administrators (DBAs)
* Developers working with PostgreSQL
* DevOps engineers
* Anyone interested in optimizing PostgreSQL performance
Contact info@mydbops.com for PostgreSQL Managed, Consulting and Remote DBA Services
The DealBook is our annual overview of the Ukrainian tech investment industry. This edition comprehensively covers the full year 2023 and the first deals of 2024.
How RPA Help in the Transportation and Logistics Industry.pptxSynapseIndia
Revolutionize your transportation processes with our cutting-edge RPA software. Automate repetitive tasks, reduce costs, and enhance efficiency in the logistics sector with our advanced solutions.
Advanced Techniques for Cyber Security Analysis and Anomaly DetectionBert Blevins
Cybersecurity is a major concern in today's connected digital world. Threats to organizations are constantly evolving and have the potential to compromise sensitive information, disrupt operations, and lead to significant financial losses. Traditional cybersecurity techniques often fall short against modern attackers. Therefore, advanced techniques for cyber security analysis and anomaly detection are essential for protecting digital assets. This blog explores these cutting-edge methods, providing a comprehensive overview of their application and importance.
Choose our Linux Web Hosting for a seamless and successful online presencerajancomputerfbd
Our Linux Web Hosting plans offer unbeatable performance, security, and scalability, ensuring your website runs smoothly and efficiently.
Visit- https://onliveserver.com/linux-web-hosting/
UiPath Community Day Kraków: Devs4Devs ConferenceUiPathCommunity
We are honored to launch and host this event for our UiPath Polish Community, with the help of our partners - Proservartner!
We certainly hope we have managed to spike your interest in the subjects to be presented and the incredible networking opportunities at hand, too!
Check out our proposed agenda below 👇👇
08:30 ☕ Welcome coffee (30')
09:00 Opening note/ Intro to UiPath Community (10')
Cristina Vidu, Global Manager, Marketing Community @UiPath
Dawid Kot, Digital Transformation Lead @Proservartner
09:10 Cloud migration - Proservartner & DOVISTA case study (30')
Marcin Drozdowski, Automation CoE Manager @DOVISTA
Pawel Kamiński, RPA developer @DOVISTA
Mikolaj Zielinski, UiPath MVP, Senior Solutions Engineer @Proservartner
09:40 From bottlenecks to breakthroughs: Citizen Development in action (25')
Pawel Poplawski, Director, Improvement and Automation @McCormick & Company
Michał Cieślak, Senior Manager, Automation Programs @McCormick & Company
10:05 Next-level bots: API integration in UiPath Studio (30')
Mikolaj Zielinski, UiPath MVP, Senior Solutions Engineer @Proservartner
10:35 ☕ Coffee Break (15')
10:50 Document Understanding with my RPA Companion (45')
Ewa Gruszka, Enterprise Sales Specialist, AI & ML @UiPath
11:35 Power up your Robots: GenAI and GPT in REFramework (45')
Krzysztof Karaszewski, Global RPA Product Manager
12:20 🍕 Lunch Break (1hr)
13:20 From Concept to Quality: UiPath Test Suite for AI-powered Knowledge Bots (30')
Kamil Miśko, UiPath MVP, Senior RPA Developer @Zurich Insurance
13:50 Communications Mining - focus on AI capabilities (30')
Thomasz Wierzbicki, Business Analyst @Office Samurai
14:20 Polish MVP panel: Insights on MVP award achievements and career profiling
RPA In Healthcare Benefits, Use Case, Trend And Challenges 2024.pptxSynapseIndia
Your comprehensive guide to RPA in healthcare for 2024. Explore the benefits, use cases, and emerging trends of robotic process automation. Understand the challenges and prepare for the future of healthcare automation
Mitigating the Impact of State Management in Cloud Stream Processing SystemsScyllaDB
Stream processing is a crucial component of modern data infrastructure, but constructing an efficient and scalable stream processing system can be challenging. Decoupling compute and storage architecture has emerged as an effective solution to these challenges, but it can introduce high latency issues, especially when dealing with complex continuous queries that necessitate managing extra-large internal states.
In this talk, we focus on addressing the high latency issues associated with S3 storage in stream processing systems that employ a decoupled compute and storage architecture. We delve into the root causes of latency in this context and explore various techniques to minimize the impact of S3 latency on stream processing performance. Our proposed approach is to implement a tiered storage mechanism that leverages a blend of high-performance and low-cost storage tiers to reduce data movement between the compute and storage layers while maintaining efficient processing.
Throughout the talk, we will present experimental results that demonstrate the effectiveness of our approach in mitigating the impact of S3 latency on stream processing. By the end of the talk, attendees will have gained insights into how to optimize their stream processing systems for reduced latency and improved cost-efficiency.
Mitigating the Impact of State Management in Cloud Stream Processing Systems
Chapter 3 Arrays in Java
1. 1
Chapter 3 Arrays : Motivations
Often you will have to store a large number of values during
the execution of a program. Suppose, for instance, that you
need to read one hundred numbers, compute their average, and
find out how many numbers are above the average. Your
program first reads the numbers and computes their average,
and then compares each number with the average to determine
whether it is above the average. The numbers must all be stored
in variables in order to accomplish this task. You have to
declare one hundred variables and repeatedly write almost
identical code one hundred times. From the standpoint of
practicality, it is impossible to write a program this way. So,
how do you solve this problem?
2. 2
Introducing Arrays
Array is a data structure that represents a collection of the
same types of data.
5.6
4.5
3.3
13.2
4
34.33
34
45.45
99.993
11123
double[] myList = new double[10];
myList reference
myList[0]
myList[1]
myList[2]
myList[3]
myList[4]
myList[5]
myList[6]
myList[7]
myList[8]
myList[9]
Element value
Array reference
variable
Array element at
index 5
3. 3
Declaring Array Variables
datatype[] arrayRefVar;
Example:
double[] myList;
datatype arrayRefVar[];
// This style is allowed, but not preferred
Example:
double myList[];
4. 4
Creating Arrays
arrayRefVar = new datatype[arraySize];
Example:
myList = new double[10];
myList[0] references the first element in the array.
myList[9] references the last element in the array.
5. 5
Declaring and Creating
in One Step
datatype[] arrayRefVar = new
datatype[arraySize];
double[] myList = new double[10];
datatype arrayRefVar[] = new
datatype[arraySize];
double myList[] = new double[10];
6. 6
The Length of an Array
Once an array is created, its size is fixed. It cannot be
changed. You can find its size using
arrayRefVar.length
For example,
myList.length returns 10
7. 7
Indexed Variables
The array elements are accessed through the index. The
array indices are 0-based, i.e., it starts from 0 to
arrayRefVar.length-1. In the example in Figure 3.1,
myList holds ten double values and the indices are
from 0 to 9.
Each element in the array is represented using the
following syntax, known as an indexed variable:
arrayRefVar[index];
8. 8
Using Indexed Variables
After an array is created, an indexed variable can
be used in the same way as a regular variable.
For example, the following code adds the value
in myList[0] and myList[1] to myList[2].
myList[2] = myList[0] + myList[1];
10. 10
Declaring, creating, initializing
Using the Shorthand Notation
double[] myList = {1.9, 2.9, 3.4, 3.5};
This shorthand notation is equivalent to the
following statements:
double[] myList = new double[4];
myList[0] = 1.9;
myList[1] = 2.9;
myList[2] = 3.4;
myList[3] = 3.5;
11. 11
CAUTION
Using the shorthand notation, you
have to declare, create, and initialize
the array all in one statement.
Splitting it would cause a syntax
error. For example, the following is
wrong:
double[] myList;
myList = {1.9, 2.9, 3.4, 3.5};
12. 12
Trace Program with Arrays
public class Test {
public static void main(String[] args) {
int[] values = new int[5];
for (int i = 1; i < 5; i++) {
values[i] = i + values[i-1];
}
values[0] = values[1] + values[4];
}
}
Declare array variable values, create an
array, and assign its reference to values
After the array is created
0
1
2
3
4
0
0
0
0
0
animation
13. 13
Trace Program with Arrays
public class Test {
public static void main(String[] args) {
int[] values = new int[5];
for (int i = 1; i < 5; i++) {
values[i] =i + values[i-1];
}
values[0] = values[1] + values[4];
}
}
i becomes 1
After the array is created
0
1
2
3
4
0
0
0
0
0
animation
14. 14
Trace Program with Arrays
public class Test {
public static void main(String[] args) {
int[] values = new int[5];
for (int i = 1; i < 5; i++) {
values[i] = i + values[i-1];
}
values[0] = values[1] + values[4];
}
}
i (=1) is less than 5
After the array is created
0
1
2
3
4
0
0
0
0
0
animation
15. 15
Trace Program with Arrays
public class Test {
public static void main(String[] args) {
int[] values = new int[5];
for (int i = 1; i < 5; i++) {
values[i] = i + values[i-1];
}
values[0] = values[1] + values[4];
}
}
After this line is executed, value[1] is 1
After the first iteration
0
1
2
3
4
0
1
0
0
0
animation
16. 16
Trace Program with Arrays
public class Test {
public static void main(String[] args) {
int[] values = new int[5];
for (int i = 1; i < 5; i++) {
values[i] = i + values[i-1];
}
values[0] = values[1] + values[4];
}
}
After i++, i becomes 2
animation
After the first iteration
0
1
2
3
4
0
1
0
0
0
17. 17
Trace Program with Arrays
public class Test {
public static void main(String[] args) {
int[] values = new int[5];
for (int i = 1; i < 5; i++) {
values[i] = i+ values[i-1];
}
values[0] = values[1] + values[4];
}
}
i (= 2) is less than 5
animation
After the first iteration
0
1
2
3
4
0
1
0
0
0
18. 18
Trace Program with Arrays
public class Test {
public static void main(String[] args) {
int[] values = new int[5];
for (int i = 1; i < 5; i++) {
values[i] = i + values[i-1];
}
values[0] = values[1] + values[4];
}
}
After this line is executed,
values[2] is 3 (2 + 1)
After the second iteration
0
1
2
3
4
0
1
3
0
0
animation
19. 19
Trace Program with Arrays
public class Test {
public static void main(String[] args) {
int[] values = new int[5];
for (int i = 1; i < 5; i++) {
values[i] = i + values[i-1];
}
values[0] = values[1] + values[4];
}
}
After this, i becomes 3.
After the second iteration
0
1
2
3
4
0
1
3
0
0
animation
20. 20
Trace Program with Arrays
public class Test {
public static void main(String[] args) {
int[] values = new int[5];
for (int i = 1; i < 5; i++) {
values[i] = i + values[i-1];
}
values[0] = values[1] + values[4];
}
}
i (=3) is still less than 5.
After the second iteration
0
1
2
3
4
0
1
3
0
0
animation
21. 21
Trace Program with Arrays
public class Test {
public static void main(String[] args) {
int[] values = new int[5];
for (int i = 1; i < 5; i++) {
values[i] = i + values[i-1];
}
values[0] = values[1] + values[4];
}
}
After this line, values[3] becomes 6 (3 + 3)
After the third iteration
0
1
2
3
4
0
1
3
6
0
animation
22. 22
Trace Program with Arrays
public class Test {
public static void main(String[] args) {
int[] values = new int[5];
for (int i = 1; i < 5; i++) {
values[i] = i + values[i-1];
}
values[0] = values[1] + values[4];
}
}
After this, i becomes 4
After the third iteration
0
1
2
3
4
0
1
3
6
0
animation
23. 23
Trace Program with Arrays
public class Test {
public static void main(String[] args) {
int[] values = new int[5];
for (int i = 1; i < 5; i++) {
values[i] = i + values[i-1];
}
values[0] = values[1] + values[4];
}
}
i (=4) is still less than 5
After the third iteration
0
1
2
3
4
0
1
3
6
0
animation
24. 24
Trace Program with Arrays
public class Test {
public static void main(String[] args) {
int[] values = new int[5];
for (int i = 1; i < 5; i++) {
values[i] = i + values[i-1];
}
values[0] = values[1] + values[4];
}
}
After this, values[4] becomes 10 (4 + 6)
After the fourth iteration
0
1
2
3
4
0
1
3
6
10
animation
25. 25
Trace Program with Arrays
public class Test {
public static void main(String[] args)
{
int[] values = new int[5];
for (int i = 1; i < 5; i++) {
values[i] = i + values[i-1];
}
values[0] = values[1] + values[4];
}
}
After i++, i becomes 5
animation
After the fourth iteration
0
1
2
3
4
0
1
3
6
10
26. 26
Trace Program with Arrays
public class Test {
public static void main(String[] args) {
int[] values = new int[5];
for (int i = 1; i < 5; i++) {
values[i] = i + values[i-1];
}
values[0] = values[1] + values[4];
}
}
i ( =5) < 5 is false. Exit the loop
animation
After the fourth iteration
0
1
2
3
4
0
1
3
6
10
27. 27
Trace Program with Arrays
public class Test {
public static void main(String[] args) {
int[] values = new int[5];
for (int i = 1; i < 5; i++) {
values[i] = i + values[i-1];
}
values[0] = values[1] + values[4];
}
}
After this line, values[0] is 11 (1 + 10)
0
1
2
3
4
11
1
3
6
10
animation
28. 28
Example: Analyzing Array Elements
Objective:
The program receives 6 numbers from the user,
Finds the largest number
And counts the occurrence of the largest number
entered.
Suppose you entered 3, 5, 2, 5, 5, and 5,
the largest number is 5
and its occurrence count is 4. TestArrayTestArray
29. 29
Problem: Assigning Grades
Objective: read student scores (int), get the best
score, and then assign grades based on the
following scheme:
– Grade is A if score is >= best–10;
– Grade is B if score is >= best–20;
– Grade is C if score is >= best–30;
– Grade is D if score is >= best–40;
– Grade is F otherwise.
AssignGradeAssignGrade
30. 30
Two-dimensional Arrays
Chicago
Boston
New York
Atlanta
Miami
Dallas
Houston
Distance Table (in miles)
Chicago Boston New York Atlanta Miami Dallas Houston
0 983 787 714 1375 967 1087
983 0 214 1102 1763 1723 1842
787 214 0 888 1549 1548 1627
714 1102 888 0 661 781 810
1375 1763 1549 661 0 1426 1187
967 1723 1548 781 1426 0 239
1087 1842 1627 810 1187 239 0
1723 1548 781 1426 0 239
Thus far, you have used one-dimensional arrays to model linear
collections of elements. You can use a two-dimensional array to
represent a matrix or a table. For example, the following table that
describes the distances between the cities can be represented using
a two-dimensional array.
31. 31
Declare/Create Two-dimensional Arrays
// Declare array ref var
dataType[][] refVar;
// Create array and assign its reference to variable
refVar = new dataType[10][10];
// Combine declaration and creation in one statement
dataType[][] refVar = new dataType[10][10];
// Alternative syntax
dataType refVar[][] = new dataType[10][10];
32. 32
Declaring Variables of Two-
dimensional Arrays and Creating
Two-dimensional Arrays
int[][] matrix = new int[10][10];
or
int matrix[][] = new int[10][10];
matrix[0][0] = 3;
for (int i = 0; i < matrix.length; i++)
for (int j = 0; j < matrix[i].length; j++)
matrix[i][j] = (int)(Math.random() * 1000);
double[][] x;
37. 37
Ragged Arrays
Each row in a two-dimensional array is itself an array. So,
the rows can have different lengths. Such an array is
known as a ragged array. For example,
int[][] matrix = {
{1, 2, 3, 4, 5},
{2, 3, 4, 5},
{3, 4, 5},
{4, 5},
{5}
};
matrix.length is 5
matrix[0].length is 5
matrix[1].length is 4
matrix[2].length is 3
matrix[3].length is 2
matrix[4].length is 1
39. 39
Problem: Grading Multiple-
Choice Test
Objective: write a
program that grades
multiple-choice test.A B A C C D E E A D
D B A B C A E E A D
E D D A C B E E A D
C B A E D C E E A D
A B D C C D E E A D
B B E C C D E E A D
B B A C C D E E A D
E B E C C D E E A D
0 1 2 3 4 5 6 7 8 9
Student 0
Student 1
Student 2
Student 3
Student 4
Student 5
Student 6
Student 7
Students’ Answers to the Questions:
D B D C C D A E A D
0 1 2 3 4 5 6 7 8 9
Key
Key to the Questions:
GradeExamGradeExam
40. 40
Problem: Finding Two Points
Nearest to Each Other
FindNearestPointsFindNearestPoints
(1, 1)
(-1, -1)
(-1, 3)
(2, 0.5)
(3, 3)
(4, 2)
(2, -1)
(4, -0.5)
-1 3
-1 -1
1 1
2 0.5
2 -1
3 3
4 2
4 -0.5
x y
0
1
2
3
4
5
6
7
41. 41
Case Study: Sudoku
5 3 7
6 1 9 5
9 8 6
8 6 3
4 8 3 1
7 2 6
6
4 1 9 5
8 7 9
5 3 4 6 7 8 9 1 2
6 7 2 1 9 5 3 4 8
1 9 8 3 4 2 5 6 7
8 5 9 7 6 1 4 2 3
4 2 6 8 5 3 7 9 1
7 1 3 9 2 4 8 5 6
9 6 1 5 3 7 2 8 4
2 8 7 4 1 9 6 3 5
3 4 5 2 8 6 1 7 9
The objective is to fill the grid (see Figure 3.2(a)) so that every row,
every column, and every 3×3 box contain the numbers 1 to 9, as
shown in Figure 3.2(b).