Richard P. Simpson Midwestern State University

Slides:



Advertisements
Similar presentations
How to Begin… ?.
Advertisements

Software Development Languages and Environments. Programming languages High level languages are problem orientated contain many English words are easier.
SAM 2007 v4 The Student Experience Including SAM Projects, SAM Exams and SAM Training.
Contest format 5 hours, around 8-12 problems One computer running (likely)Linux, plus printer 3 people on one machine No cell phones, calculators, USB.
Zhang Hongyi CSCI2100B Data Structures Tutorial 2
C Programming for engineers Teaching assistant: Ben Sandbank Home page:
EPFL ACM ICPC Qualifiers Program Committee I&C, EPFL.
7 Anup Kalbalia – Lead, CodeChef.
CS110/CS119 Introduction to Computing (Java)
SqlReports Dean Dahlvang PSUG-MO March About Dean Dean Dahlvang Director of Administrative Technology for the Proctor.
COMP Introduction to Programming Yi Hong May 13, 2015.
9 Chapter Nine Compiled Web Server Programs. 9 Chapter Objectives Learn about Common Gateway Interface (CGI) Create CGI programs that generate dynamic.
CS 2133: Data Structures Introduction and Semester Plan R. P. Simpson.
CS 114 – Class 02 Topics  Computer programs  Using the compiler Assignments  Read pages for Thursday.  We will go to the lab on Thursday.
CS 390 Unix Programming Summer Unix Programming - CS 3902 Course Details Online Information Please check.
BIT 285: ( Web) Application Programming Lecture 15: Tuesday, February 24, 2015 Microsoft Azure Instructor: Craig Duckett.
240-Current Research Easily Extensible Systems, Octave, Input Formats, SOA.
1 Getting Started with C++. 2 Objective You will be able to create, compile, and run a very simple C++ program on Windows, using Visual Studio 2008.
Chapter 1 Computers, Compilers, & Unix. Overview u Computer hardware u Unix u Computer Languages u Compilers.
Parent User Guide. Introduction to MySchoolAccount.com In this training guide, you will cover the following: 1. Creating an account at myschoolaccount.com.
SchoolSuccess for Coordinators
SQL Database Management
Invitation to Computer Science 6th Edition
Networking CS 3470, Section 1 Sarah Diesburg
Lecture 1b- Introduction
CS1010: Intro Workshop.
Tips and Tricks to Help Your Team Succeed
CSc 1302 Principles of Computer Science II
Computer Terms Review from what language did C++ originate?
Introduction to Programming
CSc 2310 Principles of Programming (Java)
Advanced Algorithms and DS CMPS 3013
A451 Theory – 7 Programming 7A, B - Algorithms.
Course: Introduction to Computers
Introduction CSE 1310 – Introduction to Computers and Programming
CMPT 409 – Competitive Programming (Spring 2018)
Understand the Programming Process
How to register and use ODMAP for Fire/EMS and other partners
Library/Learning Center Resources for Faculty
Fix Bitdefender Internet Security Error 217 Bitdefender Support Number Give a Ring on:
Quick Start Guide for Visual Studio 2010
Barbara Palmer APD Director
Welcome to CS 1010! Algorithmic Problem Solving.
Some Tips for Using Eclipse
Using the Online Ag Business Planning Tool “AGPLAN
Learning to Program in Python
Geo 318 – Introduction to GIS Programming
ENC 3254: Professional communication for Engineers
How to Run a Java Program
Learning to Program in Python
GRUNTMASTER6000 A leading innovation for future programmers.
How to Run a Java Program
Understand the Programming Process
Searching effective on Google
with Pearson’s MyITLab for Office 2010
CSCE 221 Professor Lupoli TAMU CSCE 221 Intro.
Intro to CIT 594
Welcome to Science!!! Things to know!.
Journal of Mountain Science (JMS)
Computer Terms Review from what language did C++ originate?
Running a Java Program using Blue Jay.
CSCE 206 Lab Structured Programming in C
Programming Assignment Tutorial
CS31 Discussion 1H Fall18: week 1
CS31 Discussion 1H Winter19: week 1
Welcome to Intro to C/C++ CISC 192
Lecture 20 – Practice Exercises 4
IS 135 Business Programming
CMPT 120 Lecture 26 – Unit 5 – Internet and Big Data
Presentation transcript:

Richard P. Simpson Midwestern State University The Appropriateness of Competitive Programming and the UVa Online Judge in the Classroom Richard P. Simpson Midwestern State University

Competitive Programming Competitive programming is a mind sport usually held over the Internet or a local network, involving participants trying to program according to provided specifications. Contestants are referred to as sport programmers

Catagories Short Term (1 to 5 hours) Long Term ( days to months) ACM-ICPC  TopCoder IOI  (secondary schools) many others Long Term ( days to months) CodeChef and others

Training Resources UVa Online Judge SPOJ others Roll your own DOMjudge Here you can develop your own problems (which are consequently new to the web!)

In the Classroom Students need considerable more practice with general problem solving. Students get a lot more work with STL Once a student has a bag of tricks, selecting the appropriate algorithm for a problem forces complexity considerations. The variety of ways students solve a particular problem results in interesting classroom discussions. (Efficiency!)

Faculty Resource The Uva online judge is a wonderful resource for problems of every imaginable type. Great for weekend projects which covers a specific topic. Run time interest is created!! Many problems force the student to handle all the corner cases. A great resource with problems for YOU to solve.

Programming Team Preparation First started using the Uva Judge to prepare for the ACM programming contest. meet once a week to work on these problems. This forced me to start solving many of these problems as well.

A full course Developed a course that has students solve 2 to 3 problems a week. Allows the study of algorithms that do not naturally appear in our usual course sequence. Reminds students of algorithms they should already know (but forgot) Many problems are of the type that are asked in interviews.

Comment on Cheating Solutions to most of these problems can be found on the web This can be partly addressed by requiring a certain approach or DS be used. Most students are serious about learning to be a better programmer/problem solver. I am not going to punish the good students by excessively worrying about cheating. Exams will level the playing field.

UVa online judge UVa Online Judge is an online automated judge for programming problems hosted by University of Valladolid. Contains over 4300 problems which is constantly being expanded. A user may submit a solution in ANSI C (C89), C++ (C++98), Pascal, Java, C++11 or Python. 

Let go to the UVa Judge https://uva.onlinejudge.org/ Create an account if you do not already have one. Login Click on Browse problems

Browse Problems click here

Problems 100-121

Solving and Submission All problems must read from stdin and write to stdout Only one file is submitted and it must have no non-library includes You may write your solution and test it using your favorite IDE such as visual studio c++ in windows code::blocks in Linux or even the cloud application repl.it

Redirect I/O in the IDE When you execute the program in your IDE you would like it to read from a data file when your program performs input. cin<< x<<y<<endl; Need to configure your IDE to do this by modifying the command line parameters i.e. add <data.dat Of course you can do everything at the command line and not worry about this.

Lets solve a trivial problem Uva 11172 Relational Operators Open up your IDE Create a data file called data.dat Copy and paste the example data into this file Redirect the I/O (set the command line params) Write code to read in the data and write out the data. ( Do this for every problem you attempt) Now solve the problem on your local machine

Submit it and then check my submissions

Possible results AC - accepted WA – wrong answer PE – presentation error CE – compilation error TLE - Time limit exceeded

I use the uHunt interface look at students submissions

Debugging There are several things one can do to help in debugging problems use Uva’s debug for interesting test data and run checks. UVa toolkit read the discussions Watch for extra lines, extra spaces at the end of a line, numerical precision etc.