Skip to main content

Posts

Collections

Collection Classes From the last two week's labs you may have already identified some issues related to arrays. We learnt that arrays holds identically typed items. However there are instances when you may requires a more flexible data structure that is capable of growing dynamically without throwing an exception (IndexOutOfRangeException) as in the case of an array. .NET framework's System.Collection classes provides a number of builtIn data structures that are dynamic and typesafe. Some of these classes are generic and others are non-Generic. Generic classes are more typesafe and requires a "type parameter" to be specified. Whereas, the non-generic classes are very loosely typed and should be avoided if possible. Non-Generic Classes System.Collections namespace consists of following non generic classes: ArrayList Queue Stack HashTable SortedList BitArray Issues related to non-generic classes:  Slower executions speed: Can be slower ...

DSDP Arrays Lab

Week 2 Lab Ex 1 In this lab we learn about Sorting an array, using ForEach loop, and Random class: Open Visual Studio 2012 Create a new project  by going to File --> New --> Project Select Visual C# --> Windows Desktop -->  Console Application In the Name field, type "W2Lab1-[Last_name]", where [Last_Name] is replaced with your last name. In the location field, give a directory location and click ok. Add code to declare and initialize an Int array that can hold 7 Integers. Using a For loop assign random numbers from the range 1 to 49 inclusive to the above array. Sort the array Using a ForEach loop display the seven numbers separated by tabs to console Week 2 Lab Ex 2  In this lab we learn about Linear Search and break: Add new console application project to the above solution Create an array which hold 20 random numbers in the range of 1 and 100. Using a For loop search for an integer given by user. Break out of the loop if the i...

Building your first ASP.NET application

Start Visual Studio and click file and then click new website. Visual Studio creates a number of files and folders for you. You will be able to see following files and folders in your solution explorer. Default.aspx Default.aspx.cs  Web.config Image folder  App_code folder  App_data folder Default.aspx This page consist of the html tags and asp tags. Visual studio designer adds the necessary html tags and asp tags as you design your web page. Page derivative Language  AutoEventWireUp CodeFile Inherits Inherit Default.aspx.cs This is the code behind file that has the c# coding that adds the logic required to build the page. Web config file App_code folder - can be used to store your entity classes App_data folder - can be used to store database or data files used in your application Image folder

.NET Framework

.NET Framework .NET Framework is a framework that consist of following two major parts: .NET Framework class library Common Language Runtime (CLR) that include CTS - Common Type System .NET Framework class library Common Language Runtime (CLR) that include CTS - Common Type System IL stored in an Assembly

Software Development Laws

Software Development Laws Conway's Law  - This law states that the organizational structure of the development team reflects in the code. Hierarchical organizational structure that are rigid can result in the poor architecture and code that would result in software that is too costly and hard to maintain. Humphrey's Law  - This law states that the users do not know the requirement until they see the software. User says "I Know It When I See It" (IKIWISI). But the traditional developer says that "What You See Is What You Get" (WYSIWYG). Here lies the problem and in my opinion may possibly contributes to the Ziv's law. Ziv's Law  - This law states that software development is unpredictable.

W3 Lab Lottery

Write a console application that mimic popular lottery. Ensure that you choose the right data structure to complete this exercise. The application asks user how many QuickPick numbers she wants. Once the user enters an integer, application should generate specified number of QuickPick numbers. The each QuickPick will have 6 integers in the range of 1-49 inclusive sorted in the ascending order without any duplicates.. Once QuickPick numbers are generated they are sorted in the ascending order and displayed on console.  Then, Winning Number is generated. If the winning number is matches the User Number. The application should calculated the reward, if any, and display appropriate message on the Console screen.    The reward is based on the following  Number of Matches Win 6/6 80.5 % of the 30million 5/6 + Bonus 5.75 % of the 30million 5/6 4.75 % of the 30million 4/6 9 % of the 30million 3/6 $10 prize 2/6 + Bonus $5 prize...

Introduction to System Analysis and Design

Information Systems  Organization today uses information systems to achieve strategic, tactical and operational advantage. Information systems capture, process, stores and retrieve information that satisfies the business requirements. They are either built for the organization or they are procured as an off-the-shelf software.   Traditional systems development life cycle (SDLC) SDLC The software systems can be built in-house. Software system development consists of a number of phases. A traditional SDLC consists of four phases - System planning and selection , system analysis , system design , and system implementation and usag e. System analysis and system design are critical phases of SDLC. System Analysis and Design System analysis and design is performed by a system analyst to ensure the effectiveness of the information system. An information system is considered to be effective when it is capable of catering the information requirements of an orga...