How to practice a language like C#?
Solution 1
I think you can try start with personal small utilities. For example, write a file backuper, personal asp.net blog site, password reminder, time tracker, etc..
the product will be used by you, so you will get exceptions or performance problems so you will be learning more..
Solution 2
You could also check out AntMe, it is a simulation of ants which you program in C#.
Solution 3
There's a few things I use for practice - admittedly, they're more algorithmic than business oriented, but lets face it business oriented stuff can get tedious if that's what you do all day long:
-
Code Golf on SO - check out the following tags that all have great mini tasks
Project Euler - found at http://projecteuler.net/
Check out other questions on SO to give you ideas of tasks to program - a great one to start off with can be found here Alternate FizzBuzz Questions
Attempt to figure out answers to questions that come up on here that you wouldn't otherwise know the answer to.
For practice in business aspects of programming, try and understand what most business wants when it comes to software and that is software to assist them to do their every day jobs. This may come down to software that does specific tasks for a user (i.e. you) or it may be software that allows storage, retrieval and reporting of business data.
- Create a project that allows you to store and retreive data using various patterns, taking note of performance differences of each - i.e. DataSet vs. DataAdapter vs. DataReader vs. LINQ-to-SQL and Stored Procedures vs. TableDirect vs. QueryStrings. There's only so many ways of storing and retrieving data from a database.
- Grab a demo database from the internet - like AdventureWorks or the infamous Northwind and write yourself reports displaying the data in various formats.
I often find that utility software I use that I find online just doesn't quite cut it. Sure some of them have some nice features, but inevitably there's always something missing. So I surf around and find a bunch of utilities that cover everything I think one of them should do, take all the best/most useful bits and [taking note of things I like about each of the tools] I write my own. The best way is to always think: "How do I want to use it" rather than "how must I use it if I program it this way".
Solution 4
I hear writing your own blog engine is a popular exercise these days.
Solution 5
Find an open-source project that you're interested in which uses this technology and try to contribute to it.
Chri.s
Updated on June 04, 2022Comments
-
Chri.s almost 2 years
As it is now I'm using query strings to bust browser cache when updating css and js. However, as noted many places, not all browsers always respects/checks for new query strings. For instance I experienced this with Internet Explorer 11 which didn't load a new js file, even though a new version with a new query string was available (and loaded in chrome).
Therefore I would like to change the actual filename of the files, to completely avoid this issue.
I would like the structure of the filename to change from e.g.
my-custom.js
tomy-custom-1231141.js
where the numbers are fetched fromfilemtime
.I've tried using the PHP
rename()
function merged with wordpresswp_register_script
, but this didn't work, and something tells me that it's wrong use ofrename()
.Is this possible - and will it make any sense to do so with regards to server usage?
In essence what I would like to happen is the following:
- Visitor HTTP requests
- Fetch
my-custom.js
- Rename/rewrite
my-custom.js
tomy-custom-1231141.js
based the file'sfilemtime
while preserving contents - Serve
my-custom-1231141.js
to the visitor
-
Sharon over 15 years"But what is the best way to practice C# if I cannot find any projects related to the language." I don't think there is ever a time when you cannot find a project related to a language. Take an app you find useful and attempt implement it in C#.
-
krosenvold over 15 yearsDuplicate stackoverflow.com/questions/319441/… and numerous others
-
scytale about 6 yearsThe question is about finding an alternative to your answer which he claims does not always work. Quote:"with Internet Explorer 11 which didn't load a new js file, even though a new version with a new query string was available "