We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent b60e0db commit 9268ccdCopy full SHA for 9268ccd
1 file changed
app/Project Tracker/Project Tracker/Statistics.cs
@@ -1,14 +1,20 @@
1
using System;
2
using System.Collections.Generic;
3
+using System.IO;
4
using System.Linq;
5
using System.Text;
6
using System.Threading.Tasks;
7
8
namespace Project_Tracker {
9
class Statistics {
10
public static int CountLines(string[] files) {
11
+ int linesOfCode = 0;
12
- return -1;
13
+ foreach (string file in files) {
14
+ linesOfCode += File.ReadLines(file).Count();
15
+ }
16
+
17
+ return linesOfCode;
18
}
19
20
0 commit comments