Create a DV dashboard to list problems by complexity, show two columns one which shows the problem name and other the complexity:

const columns = ['Problem name', 'Difficulty', 'Tags', 'Time complexity', 'Time taken'];
// all problem with value [complexity:: medium] should appear first
let tag = '#gfg_dsa_problem';
let pages = DataviewAPI.pages(tag);
function removeTag(tags, tagToRemove) {
	const newTags = [];
	tags.forEach((tag) => {
		if (tag !== tagToRemove) {
			newTags.push(tag)
		};
	});
	return newTags;
}
let pageNameandTags = pages
	    .sort( page => page.file.name)
	    .map(page => [page.file.link, page.difficulty, removeTag(page.file.tags, tag), page['time complexity'], page['time-taken']]);
dv.table(columns, 
	    pageNameandTags);