This is a private module sandbox of Dixtosa, for his own experimentation. Items in this module may be added and removed at Dixtosa's discretion; do not rely on this module's stability.


local e = {}

function e.main(frame)
	local args = frame:getParent().args;
	local letter = args[1];
	local upto = tonumber(args[2]);
	local initial = tonumber(args[3]);
	local Pages = "[[User:Brian0918/Hotlist/" .. letter.. "|".. letter.."]]";
	
	local iterator = 2;
	_, Lines = mw.title.new("User:Brian0918/Hotlist/"..letter):getContent():gsub('#', '#');
	while iterator <= upto do
		_,line=mw.title.new("User:Brian0918/Hotlist/"..letter..iterator):getContent():gsub('#', '#');
		Lines = Lines + line
		Pages = Pages .. ", [[User:Brian0918/Hotlist/" .. letter .. iterator .. "|".. letter .. iterator .."]]";
		iterator = iterator + 1
	end
	
	return Pages .. "||" .. initial .. "||" .. Lines .. "||" .. mw.ustring.format("%.2f%%", 100*(initial - Lines) / initial);
end


function e.getRemaining(frame)
	local args = frame:getParent().args;
	local letter = args[1];
	local upto = tonumber(args[2]);
	local initial = tonumber(args[3]);
	local Pages = "[[User:Brian0918/Hotlist/" .. letter.. "|".. letter.."]]";
	
	local iterator = 2;
	_, Lines = mw.title.new("User:Brian0918/Hotlist/"..letter):getContent():gsub('#', '#');
	while iterator <= upto do
		_,line=mw.title.new("User:Brian0918/Hotlist/"..letter..iterator):getContent():gsub('#', '#');
		Lines = Lines + line
		Pages = Pages .. ", [[User:Brian0918/Hotlist/" .. letter .. iterator .. "|".. letter .. iterator .."]]";
		iterator = iterator + 1
	end
	
	return Lines .. ""
end



return e